]> BookStack Code Mirror - bookstack/blobdiff - app/Settings/StatusController.php
Perms: Fixed some issues made when adding transactions
[bookstack] / app / Settings / StatusController.php
index 9559e344ce20ded960212d74d588a0c972e41a59..e4321bf30dba59e2ada9a2973f5a99d0e86aae0e 100644 (file)
@@ -2,7 +2,7 @@
 
 namespace BookStack\Settings;
 
-use BookStack\Http\Controllers\Controller;
+use BookStack\Http\Controller;
 use Illuminate\Support\Facades\Cache;
 use Illuminate\Support\Facades\DB;
 use Illuminate\Support\Facades\Session;
@@ -20,10 +20,11 @@ class StatusController extends Controller
                 return DB::table('migrations')->count() > 0;
             }),
             'cache' => $this->trueWithoutError(function () {
-                $rand = Str::random();
-                Cache::add('status_test', $rand);
+                $rand = Str::random(12);
+                $key = "status_test_{$rand}";
+                Cache::add($key, $rand);
 
-                return Cache::pull('status_test') === $rand;
+                return Cache::pull($key) === $rand;
             }),
             'session' => $this->trueWithoutError(function () {
                 $rand = Str::random();