Closed Dave181295 closed 2 years ago
Okay I checked your code and you should change
private static var deviceLanguage: String? {
return (Locale.current as NSLocale).object(forKey: NSLocale.Key.languageCode) as? String
}
With this approach
private static var deviceLanguage: String? {
return NSLocale.preferredLanguages[0].split(separator: "-").map{String($0)}[0]
}
if the search is in arabic/hebrew the result will still be in English, please add a parameter let us change the result's language