toArray(); return response()->json(['user' => $user], 200); } public function isLoginFilsCorrect(Request $req) { $user = User::where('email', $req->email)->where('password', Hash::make($req->password))->find(); if ($user) return "yes"; return "no"; } /** * Update the specified resource in storage. */ public function update(Request $request, string $id) { // } /** * Remove the specified resource from storage. */ public function destroy(string $id) { // } }