mirror of
https://github.com/internetee/registry.git
synced 2025-05-17 17:59:47 +02:00
Story#112965483 - we need to return from method, no iteration here
This commit is contained in:
parent
2fea2975f6
commit
54c86e15a3
2 changed files with 4 additions and 4 deletions
|
@ -19,7 +19,7 @@ class BlockedDomain < ActiveRecord::Base
|
|||
end
|
||||
|
||||
def generate_data
|
||||
next if Domain.where(name: name).any?
|
||||
return if Domain.where(name: name).any?
|
||||
|
||||
@json = generate_json
|
||||
@body = generate_body
|
||||
|
@ -48,7 +48,7 @@ class BlockedDomain < ActiveRecord::Base
|
|||
end
|
||||
|
||||
def remove_data
|
||||
next if Domain.where(name: name).any?
|
||||
return if Domain.where(name: name).any?
|
||||
|
||||
Whois::Record.where(name: name).delete_all
|
||||
end
|
||||
|
|
|
@ -30,7 +30,7 @@ class ReservedDomain < ActiveRecord::Base
|
|||
end
|
||||
|
||||
def generate_data
|
||||
next if Domain.where(name: name).any?
|
||||
return if Domain.where(name: name).any?
|
||||
|
||||
@json = generate_json
|
||||
@body = generate_body
|
||||
|
@ -59,7 +59,7 @@ class ReservedDomain < ActiveRecord::Base
|
|||
end
|
||||
|
||||
def remove_data
|
||||
next if Domain.where(name: name).any?
|
||||
return if Domain.where(name: name).any?
|
||||
|
||||
Whois::Record.where(name: name).delete_all
|
||||
end
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue