diff options
author | Janne Heß <janne@hess.ooo> | 2019-03-06 19:28:07 +0100 |
---|---|---|
committer | msquare <msquare@notrademark.de> | 2019-03-09 13:53:08 +0100 |
commit | 69ac1b2d2115a41afe2bd4527abadda70063019a (patch) | |
tree | 361f1ab05961526a94bf13429c32a03b6a4c8389 /includes/pages | |
parent | afa4506e11f96d05a727e591301f98fb50f8fad4 (diff) |
Support disabling the arrival feature
Setting `autoarrive` to true will now cause all newly registered angels
to be automatically confirmed as arrived.
Diffstat (limited to 'includes/pages')
-rw-r--r-- | includes/pages/guest_login.php | 7 |
1 files changed, 6 insertions, 1 deletions
diff --git a/includes/pages/guest_login.php b/includes/pages/guest_login.php index f507548b..c636a36c 100644 --- a/includes/pages/guest_login.php +++ b/includes/pages/guest_login.php @@ -217,7 +217,12 @@ function guest_register() ->associate($user) ->save(); - (new State())->user() + $state = new State([]); + if (config('autoarrive')) { + $state->arrived = true; + $state->arrival_date = new Carbon(); + } + $state->user() ->associate($user) ->save(); |