Skip to content

Commit 27fcb93

Browse files
committed
updates
1 parent 68dd262 commit 27fcb93

File tree

1 file changed

+2
-18
lines changed

1 file changed

+2
-18
lines changed

app/views/api/qdc/resources/country_language_preference.json.streamer

Lines changed: 2 additions & 18 deletions
Original file line numberDiff line numberDiff line change
@@ -59,25 +59,9 @@ json.object! do
5959
json.default_wbw_language nil
6060
end
6161

62-
if @data[:default_locale]
63-
json.default_locale do
64-
json.object! do
65-
json.extract! @data[:default_locale], :id, :name, :iso_code
66-
end
67-
end
68-
else
69-
json.default_locale nil
70-
end
62+
json.default_locale @data[:default_locale]&.iso_code
7163

72-
if @data[:qr_default_locale]
73-
json.qr_default_locale do
74-
json.object! do
75-
json.extract! @data[:qr_default_locale], :id, :name, :iso_code
76-
end
77-
end
78-
else
79-
json.qr_default_locale nil
80-
end
64+
json.qr_default_locale @data[:qr_default_locale]&.iso_code
8165

8266
if @data[:default_reciter]
8367
json.default_reciter do

0 commit comments

Comments
 (0)