Removed debug lines

Signed-off-by: snipe <snipe@snipe.net>
This commit is contained in:
snipe 2024-05-16 15:09:27 +01:00
parent de088d452f
commit 45eda0f611

View file

@ -262,7 +262,6 @@ final class Company extends SnipeModel
if (! static::isFullMultipleCompanySupportEnabled() || (Auth::check() && Auth::user()->isSuperUser()) || (! Auth::check())) { if (! static::isFullMultipleCompanySupportEnabled() || (Auth::check() && Auth::user()->isSuperUser()) || (! Auth::check())) {
return $query; return $query;
} else { } else {
\Log::debug('Fire scopeCompanyablesDirectly.');
return static::scopeCompanyablesDirectly($query, $column, $table_name); return static::scopeCompanyablesDirectly($query, $column, $table_name);
} }
} }
@ -275,7 +274,6 @@ final class Company extends SnipeModel
{ {
// Get the company ID of the logged in user, or set it to null if there is no company assicoated with the user // Get the company ID of the logged in user, or set it to null if there is no company assicoated with the user
if (Auth::user()) { if (Auth::user()) {
\Log::debug('Admin company is: '.Auth::user()->company_id);
$company_id = Auth::user()->company_id; $company_id = Auth::user()->company_id;
} else { } else {
$company_id = null; $company_id = null;
@ -283,9 +281,6 @@ final class Company extends SnipeModel
// Dynamically get the table name if it's not passed in, based on the model we're querying against // Dynamically get the table name if it's not passed in, based on the model we're querying against
$table = ($table_name) ? $table_name."." : $query->getModel()->getTable()."."; $table = ($table_name) ? $table_name."." : $query->getModel()->getTable().".";
\Log::debug('Model is: '.$query->getModel());
\Log::debug('Table is: '.$table);
// If the column exists in the table, use it to scope the query // If the column exists in the table, use it to scope the query
if (\Schema::hasColumn($query->getModel()->getTable(), $column)) { if (\Schema::hasColumn($query->getModel()->getTable(), $column)) {