From 69ac1b2d2115a41afe2bd4527abadda70063019a Mon Sep 17 00:00:00 2001 From: Janne Heß Date: Wed, 6 Mar 2019 19:28:07 +0100 Subject: Support disabling the arrival feature Setting `autoarrive` to true will now cause all newly registered angels to be automatically confirmed as arrived. --- includes/pages/guest_login.php | 7 ++++++- 1 file changed, 6 insertions(+), 1 deletion(-) (limited to 'includes/pages') 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(); -- cgit v1.3.1