mirror of
https://github.com/discourse/discourse.git
synced 2025-05-22 22:43:33 +08:00
FEATURE: support disabling emails for non-staff users
This commit is contained in:
@ -75,7 +75,7 @@ class ImportScripts::Base
|
||||
min_personal_message_post_length: 1,
|
||||
min_personal_message_title_length: 1,
|
||||
allow_duplicate_topic_titles: true,
|
||||
disable_emails: true,
|
||||
disable_emails: "non-staff",
|
||||
max_attachment_size_kb: 102400,
|
||||
max_image_size_kb: 102400,
|
||||
authorized_extensions: '*'
|
||||
|
@ -70,7 +70,7 @@ class ImportScripts::IpboardSQL < ImportScripts::Base
|
||||
# Site settings #
|
||||
#################
|
||||
# don't send any emails
|
||||
SiteSetting.disable_emails = true
|
||||
SiteSetting.disable_emails = "non-staff"
|
||||
# don't send digests (so you can enable email without users noticing)
|
||||
SiteSetting.disable_digest_emails = true
|
||||
# keep site and users private
|
||||
|
@ -27,7 +27,7 @@ class ImportScripts::Mbox < ImportScripts::Base
|
||||
BATCH_SIZE = 1000
|
||||
|
||||
# Site settings
|
||||
SiteSetting.disable_emails = true
|
||||
SiteSetting.disable_emails = "non-staff"
|
||||
|
||||
# Comment out if each file contains a single message
|
||||
# Use formail to split yourself: http://linuxcommand.org/man_pages/formail1.html
|
||||
|
@ -24,7 +24,7 @@ class ImportScripts::Modx < ImportScripts::Base
|
||||
def initialize
|
||||
super
|
||||
|
||||
SiteSetting.disable_emails = true
|
||||
SiteSetting.disable_emails = "non-staff"
|
||||
|
||||
@old_username_to_new_usernames = {}
|
||||
|
||||
|
@ -37,7 +37,7 @@ class ImportScripts::MyBB < ImportScripts::Base
|
||||
end
|
||||
|
||||
def execute
|
||||
SiteSetting.disable_emails = true
|
||||
SiteSetting.disable_emails = "non-staff"
|
||||
import_users
|
||||
import_categories
|
||||
import_posts
|
||||
|
@ -33,7 +33,7 @@ class ImportScripts::MylittleforumSQL < ImportScripts::Base
|
||||
QUIET = true
|
||||
|
||||
# Site settings
|
||||
SiteSetting.disable_emails = true
|
||||
SiteSetting.disable_emails = "non-staff"
|
||||
if FORCE_HOSTNAME
|
||||
SiteSetting.force_hostname = FORCE_HOSTNAME
|
||||
end
|
||||
|
Reference in New Issue
Block a user