Skip to content

Commit 1107579

Browse files
authored
Merge pull request #34 from Xatta-Trone/main
fix grad level
2 parents 81847bd + d031705 commit 1107579

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

app/Http/Controllers/Api/Admin/UserController.php

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -77,7 +77,7 @@ public function store(UserCreateRequest $request)
7777
], 422);
7878
}
7979

80-
$userdata = $checkForStudentInDB != null ? array_merge($request->validated(), ['name' => $checkForStudentInDB->student_name, 'student_id' => $student_id_without_prefix, 'max_devices' => config('user.allowed_device_number')]) : array_merge($request->validated(), ['student_id' => $student_id_without_prefix, 'max_devices' => config('user.allowed_device_number')]);
80+
$userdata = $checkForStudentInDB != null ? array_merge($request->validated(), ['name' => $checkForStudentInDB->student_name, 'student_id' => $student_id_without_prefix,, 'grad_level' => $checkForStudentInDB->grad_level, 'max_devices' => config('user.allowed_device_number')]) : array_merge($request->validated(), ['student_id' => $student_id_without_prefix, 'grad_level' => 'UG', 'max_devices' => config('user.allowed_device_number')]);
8181

8282
return $this->createNewAccount($userdata, $checkForStudentInDB != null ? $checkForStudentInDB->id : null, true);
8383
}

0 commit comments

Comments
 (0)