root 5 years ago
parent
commit
f74c25c44f
1 changed files with 12 additions and 1 deletions
  1. 12 1
      app/Http/Controllers/TutorialController.php

+ 12 - 1
app/Http/Controllers/TutorialController.php

@@ -16,6 +16,17 @@ class TutorialController extends Controller
     }
 
     public function getAppleID () {
-
+        $user = User::find($request->session()->get('id'));
+        if ($user->expired_at < time()) {
+            return response([
+                'data' => false
+            ])
+        }
+        return response([
+            'data' => [
+                'apple_id' => config('v2board.apple_id'),
+                'apple_id_password' => config('v2board.apple_id_password')
+            ]
+        ])
     }
 }