Skip to content

Commit 83eab66

Browse files
committed
Fix an error in socialiteLogin
1 parent 312a5f5 commit 83eab66

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

backend/app/Http/Controllers/LoginController.php

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -242,7 +242,7 @@ public function socialiteLogin(Request $request, string $provider)
242242
$found = false;
243243
while(!$found) {
244244
$current = $uniqueName.$num;
245-
if (!Arr::first($users->toArray(), fn($val) => Str::lower($val->unique_name) === $current)) {
245+
if (!$users->first(fn($val) => Str::lower($val->unique_name) === Str::lower($current))) {
246246
$uniqueName = $current;
247247
$found = true;
248248
} else {

0 commit comments

Comments
 (0)