From cd947ba16121375810efddd2fecaa771e66d799e Mon Sep 17 00:00:00 2001 From: Craig Williams Date: Fri, 11 Feb 2022 11:17:59 +0000 Subject: [PATCH] Jiggled the config file a little bit --- config/default.php | 2 -- src/Controller/OrganisationRegistrationController.php | 4 ++-- 2 files changed, 2 insertions(+), 4 deletions(-) diff --git a/config/default.php b/config/default.php index 13a12cf..7a8fb7b 100644 --- a/config/default.php +++ b/config/default.php @@ -18,8 +18,6 @@ return [ 'organisation' => [ 'registration' => [ 'require_approval' => true, - ], - 'approval' => [ 'timeout' => -1, ], ], diff --git a/src/Controller/OrganisationRegistrationController.php b/src/Controller/OrganisationRegistrationController.php index e71ac02..d99c907 100644 --- a/src/Controller/OrganisationRegistrationController.php +++ b/src/Controller/OrganisationRegistrationController.php @@ -135,7 +135,7 @@ class OrganisationRegistrationController extends SimpleController ]); if ($config['organisation.registration.require_approval']) { - $timeout = $this->ci->config['organisation.approval.timeout']; + $timeout = $this->ci->config['organisation.registration.timeout']; // Try to generate a new approval request $approval = $this->ci->repoOrganisationApproval->create($organisation, $currentUser, $timeout); @@ -644,7 +644,7 @@ class OrganisationRegistrationController extends SimpleController */ protected function sendApprovalEmail(UserInterface $requester, OrganisationInterface $organisation, $token) { - $timeout = $this->ci->config['organisation.approval.timeout']; + $timeout = $this->ci->config['organisation.registration.timeout']; // Create and send approval email $message = new TwigMailMessage($this->ci->view, 'mail/organisation-approval-request.html.twig');