瀏覽代碼

Update AuthLogin listener

Daniel Supernault 4 年之前
父節點
當前提交
ef184a2cb4
共有 1 個文件被更改,包括 1 次插入1 次删除
  1. 1 1
      app/Listeners/AuthLogin.php

+ 1 - 1
app/Listeners/AuthLogin.php

@@ -42,7 +42,7 @@ class AuthLogin
     protected function userProfile($user)
     {
         if (empty($user->profile)) {
-            if($user->created_at->lt(now()->subDays(1))) {
+            if($user->created_at->lt(now()->subDays(1)) && empty($user->status)) {
                 $p = Profile::withTrashed()->whereUserId($user->id)->first();
                 if($p) {
                     $p->restore();