Merge branch 'master' of https://github.com/cachethq/Cachet
This commit is contained in:
@@ -21,6 +21,7 @@ class SetupController extends Controller {
|
||||
*/
|
||||
public function postIndex() {
|
||||
$postData = Input::get();
|
||||
|
||||
$v = Validator::make($postData, [
|
||||
'settings.app_name' => 'required',
|
||||
'settings.app_domain' => 'required',
|
||||
@@ -34,7 +35,7 @@ class SetupController extends Controller {
|
||||
// Pull the user details out.
|
||||
$userDetails = array_pull($postData, 'user');
|
||||
|
||||
User::create([
|
||||
$user = User::create([
|
||||
'username' => $userDetails['username'],
|
||||
'email' => $userDetails['email'],
|
||||
'password' => $userDetails['password'],
|
||||
|
||||
@@ -11,18 +11,22 @@ class User extends Eloquent implements UserInterface, RemindableInterface {
|
||||
|
||||
/**
|
||||
* The database table used by the model.
|
||||
*
|
||||
* @var string
|
||||
*/
|
||||
protected $table = 'users';
|
||||
|
||||
/**
|
||||
* The attributes excluded from the model's JSON form.
|
||||
*
|
||||
* @var array
|
||||
*/
|
||||
protected $hidden = ['password', 'remember_token'];
|
||||
|
||||
/**
|
||||
* Items which can be mass assigned.
|
||||
* @var array
|
||||
*/
|
||||
protected $fillable = ['username'];
|
||||
|
||||
/**
|
||||
* Hash any password being inserted by default
|
||||
*
|
||||
|
||||
Reference in New Issue
Block a user