Skip to content

Instantly share code, notes, and snippets.

@parzibyte
Created August 15, 2022 01:11
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save parzibyte/95edb274f140516c0a61c92c275aa9dc to your computer and use it in GitHub Desktop.
Save parzibyte/95edb274f140516c0a61c92c275aa9dc to your computer and use it in GitHub Desktop.
<?php
/**
* Store a newly created resource in storage.
*
* @param \App\Http\Requests\StoreUserRequest $request
* @return \Illuminate\Http\Response
*/
public function store(StoreUserRequest $request)
{
$user = new User($request->input());
$user->password = Hash::make($request->input("password"));
$user->saveOrFail();
return redirect()->back()->with("mensaje", "Usuario registrado correctamente");
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment