Remove REGISTER_ADMIN_NOTIFICATION
authorTim Düsterhus <duesterhus@woltlab.com>
Mon, 2 Nov 2020 09:21:05 +0000 (10:21 +0100)
committerTim Düsterhus <duesterhus@woltlab.com>
Mon, 2 Nov 2020 09:21:05 +0000 (10:21 +0100)
Resolves #3674

com.woltlab.wcf/option.xml
constants.php
wcfsetup/install/files/lib/form/RegisterForm.class.php
wcfsetup/install/files/lib/system/WCF.class.php
wcfsetup/install/lang/de.xml
wcfsetup/install/lang/en.xml

index a9730c1870f667e387badf2fc822b2a303158f9d..5b8cd62f3f40752490729e5bbb61b4e98aad43bf 100644 (file)
@@ -1160,17 +1160,13 @@ XING</selectoptions>
                        <option name="register_disabled">
                                <categoryname>user.register</categoryname>
                                <optiontype>boolean</optiontype>
-                               <enableoptions>!register_enable_disclaimer,!register_admin_notification,!register_activation_method</enableoptions>
+                               <enableoptions>!register_enable_disclaimer,!register_activation_method</enableoptions>
                        </option>
                        <option name="register_enable_disclaimer">
                                <categoryname>user.register</categoryname>
                                <optiontype>boolean</optiontype>
                                <defaultvalue>1</defaultvalue>
                        </option>
-                       <option name="register_admin_notification">
-                               <categoryname>user.register</categoryname>
-                               <optiontype>boolean</optiontype>
-                       </option>
                        <option name="register_activation_method">
                                <categoryname>user.register</categoryname>
                                <optiontype>radioButton</optiontype>
@@ -1703,5 +1699,6 @@ DESC:wcf.global.sortOrder.descending</selectoptions>
        <delete>
                <option name="http_enable_gzip" />
                <option name="meta_keywords" />
+               <option name="register_admin_notification" />
        </delete>
 </data>
index 2b118d379a8924bc0e04c1411f29dbc3781e9dae..5748d676daf8c7e45f0891bb71d716ce966b630f 100644 (file)
@@ -142,7 +142,6 @@ define('REGISTER_FORBIDDEN_EMAILS', '');
 define('REGISTER_ALLOWED_EMAILS', '');
 define('REGISTER_DISABLED', 0);
 define('REGISTER_ENABLE_DISCLAIMER', 1);
-define('REGISTER_ADMIN_NOTIFICATION', 0);
 define('REGISTER_ACTIVATION_METHOD', '1');
 define('REGISTER_USERNAME_MIN_LENGTH', 3);
 define('REGISTER_USERNAME_MAX_LENGTH', 25);
index 1bffc5af22656a2b36f92fcc866c62f7571b2daa..1c02be1c0b6907df98751903ef6f3b2cb9735a43 100644 (file)
@@ -524,18 +524,6 @@ class RegisterForm extends UserAddForm {
                        $this->message = 'wcf.user.register.success.awaitActivation';
                }
                
-               // notify admin
-               if (REGISTER_ADMIN_NOTIFICATION) {
-                       // get default language
-                       $language = LanguageFactory::getInstance()->getDefaultLanguage();
-                       
-                       $email = new Email();
-                       $email->addRecipient(new Mailbox(MAIL_ADMIN_ADDRESS, null, $language));
-                       $email->setSubject($language->getDynamicVariable('wcf.user.register.notification.mail.subject'));
-                       $email->setBody(new PlainTextMimePart($language->getDynamicVariable('wcf.user.register.notification.mail', ['user' => $user])));
-                       $email->send();
-               }
-               
                $this->fireNotificationEvent($user);
                
                if ($this->captchaObjectType) {
index 699b7d0adcf650c654284dc9d090c81db2b60999..90cc4acb403a5c17e107ba08fbe5440d0f147f46 100644 (file)
@@ -381,6 +381,10 @@ class WCF {
                // https://github.com/WoltLab/WCF/issues/3561
                define('META_KEYWORDS', '');
                
+               // The admin notification is redundant and removed in 5.4.
+               // https://github.com/WoltLab/WCF/issues/3674
+               define('REGISTER_ADMIN_NOTIFICATION', 0);
+               
                $filename = WCF_DIR.'options.inc.php';
                
                // create options file if doesn't exist
index a0ebe1cc2359924ba0c4a0c6cdd04ff08b7d2e8a..487c6c1b1d773ed11b9f2647ec776fd539f7a23a 100644 (file)
@@ -1478,7 +1478,6 @@ ACHTUNG: Die oben genannten Meldungen sind stark gekürzt. Sie können Details z
                <item name="wcf.acp.option.register_disabled.description"><![CDATA[Schaltet die Registrierung für neue Benutzer gänzlich ab. Neue Benutzer können nur noch manuell durch den Administrator angelegt werden.]]></item>
                <item name="wcf.acp.option.register_enable_disclaimer"><![CDATA[Nutzungsbedingungen aktivieren]]></item>
                <item name="wcf.acp.option.register_enable_disclaimer.description"><![CDATA[Die Nutzungsbedingungen müssen durch den Benutzer vor der Registrierung akzeptiert werden.]]></item>
-               <item name="wcf.acp.option.register_admin_notification"><![CDATA[Administrator über neue Registrierungen per E-Mail benachrichtigen]]></item>
                <item name="wcf.acp.option.register_activation_method"><![CDATA[Aktivierungsmethode]]></item>
                <item name="wcf.acp.option.register_activation_method.byAdmin"><![CDATA[Aktivierung erfolgt durch Administrator]]></item>
                <item name="wcf.acp.option.register_activation_method.byUser"><![CDATA[Benutzer aktiviert sich durch E-Mail-Bestätigung]]></item>
index 0863d05e37a7de6df22384b3a41648f59f6dc426..6859a184e7add33ff39f80892ff4af2a191810bd 100644 (file)
@@ -1457,7 +1457,6 @@ ATTENTION: The messages listed above are greatly shortened. You can view details
                <item name="wcf.acp.option.register_disabled.description"><![CDATA[Disables registration for all users, new users can be created through an administrator.]]></item>
                <item name="wcf.acp.option.register_enable_disclaimer"><![CDATA[Enable disclaimer]]></item>
                <item name="wcf.acp.option.register_enable_disclaimer.description"><![CDATA[Disclaimer must be accepted during registration.]]></item>
-               <item name="wcf.acp.option.register_admin_notification"><![CDATA[Notify administrator of new registrations]]></item>
                <item name="wcf.acp.option.register_activation_method"><![CDATA[Registration Approval Method]]></item>
                <item name="wcf.acp.option.register_activation_method.byAdmin"><![CDATA[Only administrators can approve registrations]]></item>
                <item name="wcf.acp.option.register_activation_method.byUser"><![CDATA[Registrations are approved through an email confirmation]]></item>