diff --git a/app/models/site_setting.rb b/app/models/site_setting.rb index 88c6e2f757c..e7f1ae0c916 100644 --- a/app/models/site_setting.rb +++ b/app/models/site_setting.rb @@ -67,7 +67,7 @@ class SiteSetting < ActiveRecord::Base setting(:num_flags_to_block_new_user, 3) setting(:num_users_to_block_new_user, 3) - setting(:notify_mods_when_user_blocked, true) + setting(:notify_mods_when_user_blocked, false) # used mainly for dev, force hostname for Discourse.base_url # You would usually use multisite for this diff --git a/spec/services/spam_rules_enforcer_spec.rb b/spec/services/spam_rules_enforcer_spec.rb index 25f711ce3b0..071571c33b4 100644 --- a/spec/services/spam_rules_enforcer_spec.rb +++ b/spec/services/spam_rules_enforcer_spec.rb @@ -122,6 +122,7 @@ describe SpamRulesEnforcer do end it 'sends private message to moderators' do + SiteSetting.stubs(:notify_mods_when_user_blocked).returns(true) moderator = Fabricate(:moderator) GroupMessage.expects(:create).with do |group, msg_type, params| group == Group[:moderators].name and msg_type == :user_automatically_blocked and params[:user].id == user.id