rabin 3 rokov pred
rodič
commit
fa8c458e86
1 zmenil súbory, kde vykonal 3 pridanie a 1 odobranie
  1. 3 1
      src/Auth.php

+ 3 - 1
src/Auth.php

@@ -31,7 +31,7 @@ class Auth
      */
     public function __construct()
     {
-        $this->save = new Oper(false, 'cookie');
+        $this->save = new Oper(false, 'session');
         $this->name = 'manage';
     }
 
@@ -190,6 +190,7 @@ class Auth
         if (!$info) {
             return;
         }
+        $state = true;
         Dever::config('base')->getAdmin = 1;
         if ($state == true && Dever::config('base')->getAdmin && $info && isset($info['id'])) {
             $admin = Dever::db('manage/admin')->one($info['id']);
@@ -203,6 +204,7 @@ class Auth
             if ($admin['company']) {
                 $info['company'] = $admin['company'];
             }
+            $info['username'] = $admin['username'];
         }