Skip to content

Commit

Permalink
fixModuleMigration
Browse files Browse the repository at this point in the history
  • Loading branch information
arthurpar06 committed Oct 17, 2023
1 parent 53264e2 commit 6974471
Showing 1 changed file with 3 additions and 3 deletions.
6 changes: 3 additions & 3 deletions app/Services/ModuleService.php
Original file line number Diff line number Diff line change
Expand Up @@ -171,7 +171,7 @@ public function addModule($module_name): bool
]);

try {
Artisan::call('module:migrate '.$module_name, ['--force' => true]);
Artisan::call('module:migrate', ['module' => $module_name, '--force' => true]);
} catch (Exception $e) {
Log::error('Error running migration for '.$module_name.'; error='.$e);
}
Expand Down Expand Up @@ -270,7 +270,7 @@ public function installModule(UploadedFile $file): FlashNotifier
}

Artisan::call('config:cache');
Artisan::call('module:migrate '.$module, ['--force' => true]);
Artisan::call('module:migrate', ['module' => $module, '--force' => true]);

return flash()->success('Module Installed');
}
Expand All @@ -295,7 +295,7 @@ public function updateModule($id, $status): bool
]);

if ($status === true) {
Artisan::call('module:migrate '.$module->name, ['--force' => true]);
Artisan::call('module:migrate', ['module' => $module->name, '--force' => true]);
}

return true;
Expand Down

0 comments on commit 6974471

Please sign in to comment.