Fix error on birthday contact creation validation fail

This commit is contained in:
Alex Sherman 2021-05-26 16:33:05 +05:00
parent 82c048b316
commit 194489e40f
2 changed files with 37 additions and 1 deletions

View file

@ -2,7 +2,7 @@ xml.epp_head do
xml.response do
@errors.each do |error|
x = error&.options
next if x.empty? || x == { value: nil }
next if x.empty? || x == { value: nil } || x[:code].blank?
xml.result('code' => x[:code]) do
xml.msg(x[:msg], 'lang' => 'en')