Add initial basic API changes

New route is `/api/me`
This commit is contained in:
Dane Everitt 2016-10-14 20:22:23 -04:00
parent 126df09152
commit 745c735b32
No known key found for this signature in database
GPG key ID: EEA66103B3D71F53
17 changed files with 587 additions and 40 deletions

View file

@ -70,7 +70,11 @@ class Subuser extends Model
*/
public function __construct()
{
self::$user = Auth::user();
if (!is_null(Auth::user())) {
self::$user = Auth::user();
} else {
throw new \Exception('Auth::user and Dingo::user cannot both be null.');
}
}
/**