paginate(10)->withQueryString(); } public function create(array $data): User { $user = User::create($data['credentials']); $student = Student::create($data['user_data']); $student->user()->save($user); return $student; } public function update($model, array $data): User { $model->update($data); return $model; } public function delete($model): void { $model->destroy(); } }