change default response for empty popularsearchservice response
This commit is contained in:
@@ -33,7 +33,7 @@ class PopularSearchService
|
|||||||
if response.success?
|
if response.success?
|
||||||
response = response.body
|
response = response.body
|
||||||
else
|
else
|
||||||
response = ""
|
response = "[]"
|
||||||
end
|
end
|
||||||
response
|
response
|
||||||
end.to_s.force_encoding("utf-8")
|
end.to_s.force_encoding("utf-8")
|
||||||
@@ -47,7 +47,7 @@ class PopularSearchService
|
|||||||
if response.success?
|
if response.success?
|
||||||
response = response.body
|
response = response.body
|
||||||
else
|
else
|
||||||
response = ""
|
response = "[]"
|
||||||
end
|
end
|
||||||
response
|
response
|
||||||
end.to_s.force_encoding("utf-8")
|
end.to_s.force_encoding("utf-8")
|
||||||
|
|||||||
Reference in New Issue
Block a user