Only check channel uniqueness within the same provider
This commit is contained in:
parent
9b229b63f9
commit
4703250c1f
|
@ -37,7 +37,7 @@ class DiscourseChat::Channel < DiscourseChat::PluginModel
|
||||||
end
|
end
|
||||||
|
|
||||||
check_unique = false
|
check_unique = false
|
||||||
matching_channels = DiscourseChat::Channel.where.not(id: id)
|
matching_channels = DiscourseChat::Channel.with_provider(provider).where.not(id: id)
|
||||||
|
|
||||||
data.each do |key, value|
|
data.each do |key, value|
|
||||||
regex_string = params.find { |p| p[:key] == key }[:regex]
|
regex_string = params.find { |p| p[:key] == key }[:regex]
|
||||||
|
|
Loading…
Reference in New Issue