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.
1 parent 76ef21a commit b05d0f3Copy full SHA for b05d0f3
src/Client.php
@@ -61,6 +61,18 @@ public function tokens()
61
return $this->hasMany(Passport::tokenModel(), 'client_id');
62
}
63
64
+ /**
65
+ * Get the user that the client belongs to.
66
+ *
67
+ * @return \Illuminate\Database\Eloquent\Relations\BelongsTo
68
+ */
69
+ public function user()
70
+ {
71
+ $provider = config('auth.guards.api.provider');
72
+
73
+ return $this->belongsTo(config('auth.providers.'.$provider.'.model'));
74
+ }
75
76
/**
77
* Determine if the client is a "first party" client.
78
*
0 commit comments