mirror of
https://github.com/internetee/registry.git
synced 2025-06-05 20:27:30 +02:00
Fix tests
This commit is contained in:
parent
f2a1ee101b
commit
220e0d7993
6 changed files with 29 additions and 31 deletions
|
@ -59,9 +59,12 @@ module Repp
|
|||
end
|
||||
end
|
||||
|
||||
def render_epp_error(status = :bad_request)
|
||||
def render_epp_error(status = :bad_request, data = {})
|
||||
@epp_errors ||= []
|
||||
@epp_errors << { code: 2304, msg: 'Command failed' } if data != {}
|
||||
|
||||
render(
|
||||
json: { code: @epp_errors[0][:code], message: @epp_errors[0][:msg] },
|
||||
json: { code: @epp_errors[0][:code], message: @epp_errors[0][:msg], data: data },
|
||||
status: status
|
||||
)
|
||||
end
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue