mirror of
https://github.com/internetee/registry.git
synced 2025-06-05 12:17:30 +02:00
fixed codeclimate error
This commit is contained in:
parent
ce218c34b9
commit
a6b37ff5ac
1 changed files with 7 additions and 5 deletions
|
@ -21,12 +21,14 @@ module Actions
|
|||
end
|
||||
|
||||
def validate_new_balance
|
||||
@error = true and return if @new_balance.blank?
|
||||
|
||||
begin
|
||||
!Float(@new_balance).nil?
|
||||
rescue StandardError
|
||||
if @new_balance.blank?
|
||||
@error = true
|
||||
else
|
||||
begin
|
||||
!Float(@new_balance).nil?
|
||||
rescue StandardError
|
||||
@error = true
|
||||
end
|
||||
end
|
||||
end
|
||||
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue