@@ -21,6 +21,8 @@ abstract class SubuserRequest extends ClientApiRequest
2121 * Authorize the request and ensure that a user is not trying to modify themselves.
2222 *
2323 * @return bool
24+ *
25+ * @throws \Illuminate\Contracts\Container\BindingResolutionException
2426 */
2527 public function authorize (): bool
2628 {
@@ -52,6 +54,8 @@ public function authorize(): bool
5254 * by the user making the request.
5355 *
5456 * @param array $permissions
57+ *
58+ * @throws \Illuminate\Contracts\Container\BindingResolutionException
5559 */
5660 protected function validatePermissionsCanBeAssigned (array $ permissions )
5761 {
@@ -78,6 +82,8 @@ protected function validatePermissionsCanBeAssigned(array $permissions)
7882 * Returns the currently authenticated user's permissions.
7983 *
8084 * @return array
85+ *
86+ * @throws \Illuminate\Contracts\Container\BindingResolutionException
8187 */
8288 public function currentUserPermissions (): array
8389 {
@@ -88,7 +94,7 @@ public function currentUserPermissions(): array
8894 try {
8995 $ model = $ repository ->findFirstWhere ([
9096 ['server_id ' , $ this ->route ()->parameter ('server ' )->id ],
91- ['user_id ' => $ this ->user ()->id ],
97+ ['user_id ' , $ this ->user ()->id ],
9298 ]);
9399 } catch (RecordNotFoundException $ exception ) {
94100 return [];
@@ -109,6 +115,7 @@ public function currentUserPermissions(): array
109115 *
110116 * @throws \Symfony\Component\HttpKernel\Exception\NotFoundHttpException
111117 * @throws \Illuminate\Database\Eloquent\ModelNotFoundException
118+ * @throws \Illuminate\Contracts\Container\BindingResolutionException
112119 */
113120 public function endpointSubuser ()
114121 {
0 commit comments