about summary refs log tree commit diff
path: root/app/lib
diff options
context:
space:
mode:
Diffstat (limited to 'app/lib')
-rw-r--r--app/lib/command_tag/commands/account_tools.rb4
-rw-r--r--app/lib/command_tag/commands/status_tools.rb4
2 files changed, 4 insertions, 4 deletions
diff --git a/app/lib/command_tag/commands/account_tools.rb b/app/lib/command_tag/commands/account_tools.rb
index 3d9fb6d4e..dd7fd0229 100644
--- a/app/lib/command_tag/commands/account_tools.rb
+++ b/app/lib/command_tag/commands/account_tools.rb
@@ -24,11 +24,11 @@ module CommandTag::Commands::AccountTools
       if args[2].blank?
         @account.user.settings.default_privacy = args[1]
       elsif args[1] == 'public'
-        domains = args[2..-1].map { |domain| normalize_domain(domain) }.uniq.compact
+        domains = args[2..-1].map { |domain| normalize_domain(domain) unless domain == '*' }.uniq.compact
         @account.domain_permissions.where(domain: domains).destroy_all if domains.present?
       else
         args[2..-1].flat_map(&:split).uniq.each do |domain|
-          domain = normalize_domain(domain)
+          domain = normalize_domain(domain) unless domain == '*'
           @account.domain_permissions.create_or_update(domain: domain, visibility: args[1]) if domain.present?
         end
       end
diff --git a/app/lib/command_tag/commands/status_tools.rb b/app/lib/command_tag/commands/status_tools.rb
index 23bdcbfc3..7eaeddbea 100644
--- a/app/lib/command_tag/commands/status_tools.rb
+++ b/app/lib/command_tag/commands/status_tools.rb
@@ -15,11 +15,11 @@ module CommandTag::Commands::StatusTools
     if args[1].blank?
       @status.visibility = args[0].to_sym
     elsif args[0] == @status.visibility.to_s
-      domains = args[1..-1].map { |domain| normalize_domain(domain) }.uniq.compact
+      domains = args[1..-1].map { |domain| normalize_domain(domain) unless domain == '*' }.uniq.compact
       @status.domain_permissions.where(domain: domains).destroy_all if domains.present?
     else
       args[1..-1].flat_map(&:split).uniq.each do |domain|
-        domain = normalize_domain(domain)
+        domain = normalize_domain(domain) unless domain == '*'
         @status.domain_permissions.create_or_update(domain: domain, visibility: args[0]) if domain.present?
       end
     end