From 11ea08df8d4784aad4836852180098c45b90c5a2 Mon Sep 17 00:00:00 2001 From: Florian Pritz Date: Fri, 18 May 2018 23:06:40 +0200 Subject: Add invitation key deletion Signed-off-by: Florian Pritz --- application/controllers/User.php | 12 ++++++++++++ 1 file changed, 12 insertions(+) (limited to 'application/controllers') diff --git a/application/controllers/User.php b/application/controllers/User.php index a2ce5c823..26704f3e5 100644 --- a/application/controllers/User.php +++ b/application/controllers/User.php @@ -133,6 +133,18 @@ class User extends MY_Controller { redirect("user/invite"); } + function delete_invitation_key() + { + $this->duser->require_implemented("can_register_new_users"); + $this->muser->require_access(); + + $userid = $this->muser->get_userid(); + $key = $this->input->post("key"); + + \service\user::delete_invitation_key($userid, $key); + redirect("user/invite"); + } + function invite() { $this->duser->require_implemented("can_register_new_users"); -- cgit v1.2.3-24-g4f1b