We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
2 parents 20dd9c8 + 4efa7f0 commit 6aaa365Copy full SHA for 6aaa365
app/Http/Controllers/AccountController.php
@@ -7,10 +7,7 @@
7
use Auth;
8
use Hash;
9
use Cloudder;
10
-use App\User;
11
use App\Http\Requests;
12
-use App\Http\Controllers\Controller;
13
-
14
15
class AccountController extends Controller
16
{
@@ -19,15 +16,13 @@ class AccountController extends Controller
19
20
17
public function __construct()
21
18
22
- $this->id = Auth::user()->id;
23
- $this->user = User::findOrFail($this->id);
+ $this->user = Auth::user();
+ $this->id = $this->user->id;
24
}
25
26
public function getAccountPage()
27
28
- $details = User::whereId($this->id)->first();
29
30
- return view('account.dashboard')->withAccount($details);
+ return view('account.dashboard')->withAccount($this->user);
31
32
33
/**
0 commit comments