Class App\Http\Controllers\UserController Does Not Exist

后端 未结 6 2572
忘掉有多难
忘掉有多难 2020-12-11 04:04

Having the issue when loading the route /users or /user/add and being return an error of;

ReflectionException in Route.php line 280: Class App\\Http

6条回答
  •  天命终不由人
    2020-12-11 04:12

    The create method was missing the correct array brackets.

    User::create([
                'email' => $input['email'],
                'password' => Hash::make($password),
                'first_name' => $input['first_name'],
                'surname' => $input['surname'],
                'phone_number' => $input['phone_number'],
                'user_type' => $input['user_type'],
            ]);
    

提交回复
热议问题