mirror of
https://github.com/librenms/librenms.git
synced 2024-10-07 16:52:45 +00:00
Fix install failing this migration (#15262)
Unsure if this the correct fix or if it even fixes the issue :D https://community.librenms.org/t/install-fails/22181
This commit is contained in:
@@ -29,7 +29,11 @@ return new class extends Migration
|
||||
}
|
||||
});
|
||||
|
||||
Bouncer::refresh(); // clear cache
|
||||
try {
|
||||
Bouncer::refresh(); // clear cache
|
||||
} catch (Exception $e) {
|
||||
// if this fails, there was no cache anyway
|
||||
}
|
||||
|
||||
Schema::table('users', function (Blueprint $table) {
|
||||
$table->dropColumn('level');
|
||||
@@ -52,7 +56,11 @@ return new class extends Migration
|
||||
$user->save();
|
||||
});
|
||||
|
||||
Bouncer::refresh();
|
||||
try {
|
||||
Bouncer::refresh(); // clear cache
|
||||
} catch (Exception $e) {
|
||||
// if this fails, there was no cache anyway
|
||||
}
|
||||
}
|
||||
|
||||
private function getLevel(User $user): int
|
||||
|
Reference in New Issue
Block a user