mirror of
https://github.com/discourse/discourse-chat-integration.git
synced 2025-03-06 17:59:29 +00:00
Ignore self when checking for duplicate rule
This commit is contained in:
parent
61fa0dbe0b
commit
28091a9a97
@ -37,7 +37,7 @@ class DiscourseChat::Channel < DiscourseChat::PluginModel
|
||||
end
|
||||
|
||||
check_unique = false
|
||||
matching_channels = DiscourseChat::Channel.all
|
||||
matching_channels = DiscourseChat::Channel.where.not(id: id)
|
||||
|
||||
data.each do |key, value|
|
||||
regex_string = params.find{|p| p[:key] == key}[:regex]
|
||||
|
Loading…
x
Reference in New Issue
Block a user