Skip to content

Commit

Permalink
Meilisearch import: round minutes
Browse files Browse the repository at this point in the history
  • Loading branch information
ilestis committed Jan 10, 2025
1 parent bc1a69e commit 3475d44
Show file tree
Hide file tree
Showing 3 changed files with 16 additions and 13 deletions.
2 changes: 1 addition & 1 deletion app/Console/Commands/SetupMeilisearch.php
Original file line number Diff line number Diff line change
Expand Up @@ -88,7 +88,7 @@ public function handle()
$object = new $model();
$this->info('Importing ' . number_format($object->count()) . ' [' . $model . '] at ' . date('H:i:s'));
$object::makeAllSearchable($this->option('chunk'));
$this->info('- Done in ' . $time->diffInMinutes() . ' min');
$this->info('- Done in ' . round($time->diffInMinutes(), 4) . ' min');
Log::info('Meilisearch', ['model' => $model]);
}
$this->info('Ended at ' . date('H:i:s') . ' after ' . $start->diffInMinutes() . ' min');
Expand Down
2 changes: 1 addition & 1 deletion app/Models/Scopes/AclScope.php
Original file line number Diff line number Diff line change
Expand Up @@ -64,7 +64,7 @@ public function apply(Builder $query, Model $model)
{
// No permission engine on console for the time being. In the future, we might want
// to build a system to limit exposing private stuff on a campaign export.
if (app()->runningInConsole() && !app()->environment('testing')) {
if (app()->runningInConsole() && (!app()->environment('testing') || config('app.skip_permissions') === true)) {
return $query;
}

Expand Down
25 changes: 14 additions & 11 deletions composer.lock

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

0 comments on commit 3475d44

Please sign in to comment.