Skip to content

Commit

Permalink
Merge pull request #79 from makeen-project/crash_and_search_fix
Browse files Browse the repository at this point in the history
Crash and search fix
  • Loading branch information
wadhawh authored Dec 6, 2024
2 parents b31ae32 + b16bcb1 commit de158f7
Show file tree
Hide file tree
Showing 2 changed files with 70 additions and 71 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -192,7 +192,7 @@ struct SearchPresentation {
init(model: GeoPlacesClientTypes.SuggestResultItem, userLocation: CLLocation? = nil) {
self.placeId = model.place?.placeId
if let fullAddress = model.place?.address?.label?.formatAddressField() {
self.name = fullAddress[safe: 0] ?? ""
self.name = fullAddress[safe: 0] ?? model.place?.address?.label
self.fullLocationAddress = fullAddress[safe: 1] ?? ""
} else {
self.name = model.title
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -73,74 +73,73 @@ struct LanguageSwitcherData: Codable {
}

let languageSwitcherData: [LanguageSwitcherData] = [
LanguageSwitcherData(value: "en", label: "English"),
LanguageSwitcherData(value: "as", label: "অসমীয়া"),
LanguageSwitcherData(value: "az", label: "Azərbaycan dili"),
LanguageSwitcherData(value: "id", label: "Bahasa Indonesia"),
LanguageSwitcherData(value: "ms", label: "Bahasa Melayu"),
LanguageSwitcherData(value: "be", label: "Беларуская"),
LanguageSwitcherData(value: "bg", label: "Български"),
LanguageSwitcherData(value: "bn", label: "বাংলা"),
LanguageSwitcherData(value: "bs", label: "Bosanski"),
LanguageSwitcherData(value: "ca", label: "Català"),
LanguageSwitcherData(value: "zh", label: "简体中文"),
LanguageSwitcherData(value: "zh-Hant", label: "繁體中文"),
LanguageSwitcherData(value: "cs", label: "Čeština"),
LanguageSwitcherData(value: "cy", label: "Cymraeg"),
LanguageSwitcherData(value: "da", label: "Dansk"),
LanguageSwitcherData(value: "de", label: "Deutsch"),
LanguageSwitcherData(value: "el", label: "Ελληνικά"),
LanguageSwitcherData(value: "en", label: "English"),
LanguageSwitcherData(value: "es", label: "Español"),
LanguageSwitcherData(value: "et", label: "Eesti"),
LanguageSwitcherData(value: "eu", label: "Euskara"),
LanguageSwitcherData(value: "fa", label: "فارسی"),
LanguageSwitcherData(value: "fi", label: "Suomi"),
LanguageSwitcherData(value: "fo", label: "Føroyskt"),
LanguageSwitcherData(value: "fr", label: "Français"),
LanguageSwitcherData(value: "gl", label: "Galego"),
LanguageSwitcherData(value: "ka", label: "ქართული"),
LanguageSwitcherData(value: "gu", label: "ગુજરાતી"),
LanguageSwitcherData(value: "he", label: "עברית"),
LanguageSwitcherData(value: "hi", label: "हिन्दी"),
LanguageSwitcherData(value: "hr", label: "Hrvatski"),
LanguageSwitcherData(value: "hu", label: "Magyar"),
LanguageSwitcherData(value: "hy", label: "Հայերեն"),
LanguageSwitcherData(value: "is", label: "Íslenska"),
LanguageSwitcherData(value: "it", label: "Italiano"),
LanguageSwitcherData(value: "ja", label: "日本語"),
LanguageSwitcherData(value: "kk", label: "Қазақ тілі"),
LanguageSwitcherData(value: "km", label: "ខ្មែរ"),
LanguageSwitcherData(value: "kn", label: "ಕನ್ನಡ"),
LanguageSwitcherData(value: "ko", label: "한국어"),
LanguageSwitcherData(value: "ky", label: "Кыргызча"),
LanguageSwitcherData(value: "lt", label: "Lietuvių"),
LanguageSwitcherData(value: "lv", label: "Latviešu"),
LanguageSwitcherData(value: "mk", label: "Македонски"),
LanguageSwitcherData(value: "ml", label: "മലയാളം"),
LanguageSwitcherData(value: "mr", label: "मराठी"),
LanguageSwitcherData(value: "mt", label: "Malti"),
LanguageSwitcherData(value: "my", label: "မြန်မာစာ"),
LanguageSwitcherData(value: "nl", label: "Nederlands"),
LanguageSwitcherData(value: "no", label: "Norsk"),
LanguageSwitcherData(value: "or", label: "ଓଡ଼ିଆ"),
LanguageSwitcherData(value: "pa", label: "ਪੰਜਾਬੀ"),
LanguageSwitcherData(value: "pl", label: "Polski"),
LanguageSwitcherData(value: "pt", label: "Português"),
LanguageSwitcherData(value: "ro", label: "Română"),
LanguageSwitcherData(value: "ru", label: "Русский"),
LanguageSwitcherData(value: "sk", label: "Slovenčina"),
LanguageSwitcherData(value: "sl", label: "Slovenščina"),
LanguageSwitcherData(value: "sq", label: "Shqip"),
LanguageSwitcherData(value: "sr", label: "Српски"),
LanguageSwitcherData(value: "sv", label: "Svenska"),
LanguageSwitcherData(value: "ta", label: "தமிழ்"),
LanguageSwitcherData(value: "te", label: "తెలుగు"),
LanguageSwitcherData(value: "th", label: "ไทย"),
LanguageSwitcherData(value: "tr", label: "Türkçe"),
LanguageSwitcherData(value: "uk", label: "Українська"),
LanguageSwitcherData(value: "uz", label: "Oʻzbek"),
LanguageSwitcherData(value: "vi", label: "Tiếng Việt")
LanguageSwitcherData(value: "en", label: "English" ), // English
LanguageSwitcherData(value: "ar", label: "العربية" ), // Arabic
LanguageSwitcherData(value: "as", label: "অসমীয়া" ), // Assamese
LanguageSwitcherData(value: "az", label: "Azərbaycan dili" ), // Azerbaijani
LanguageSwitcherData(value: "be", label: "беларуская" ), // Belarusian
LanguageSwitcherData(value: "bg", label: "български" ), // Bulgarian
LanguageSwitcherData(value: "bn", label: "বাংলা" ), // Bengali
LanguageSwitcherData(value: "bs", label: "Bosanski" ), // Bosnian
LanguageSwitcherData(value: "ca", label: "Català" ), // Catalan
LanguageSwitcherData(value: "cs", label: "Čeština" ), // Czech
LanguageSwitcherData(value: "cy", label: "Cymraeg" ), // Welsh
LanguageSwitcherData(value: "da", label: "Dansk" ), // Danish
LanguageSwitcherData(value: "de", label: "Deutsch" ), // German
LanguageSwitcherData(value: "el", label: "Ελληνικά" ), // Greek
LanguageSwitcherData(value: "es", label: "Español" ), // Spanish
LanguageSwitcherData(value: "et", label: "Eesti" ), // Estonian
LanguageSwitcherData(value: "eu", label: "Euskara" ), // Basque
LanguageSwitcherData(value: "fi", label: "Suomi" ), // Finnish
LanguageSwitcherData(value: "fo", label: "Føroyskt" ), // Faroese
LanguageSwitcherData(value: "fr", label: "Français" ), // French
LanguageSwitcherData(value: "ga", label: "Gaeilge" ), // Irish
LanguageSwitcherData(value: "gl", label: "Galego" ), // Galician
LanguageSwitcherData(value: "gn", label: "Avañe'ẽ" ), // Guarani
LanguageSwitcherData(value: "gu", label: "ગુજરાતી" ), // Gujarati
LanguageSwitcherData(value: "he", label: "עברית" ), // Hebrew
LanguageSwitcherData(value: "hi", label: "हिन्दी" ), // Hindi
LanguageSwitcherData(value: "hr", label: "Hrvatski" ), // Croatian
LanguageSwitcherData(value: "hu", label: "Magyar" ), // Hungarian
LanguageSwitcherData(value: "hy", label: "Հայերեն" ), // Armenian
LanguageSwitcherData(value: "id", label: "Bahasa Indonesia" ), // Indonesian
LanguageSwitcherData(value: "is", label: "Íslenska" ), // Icelandic
LanguageSwitcherData(value: "it", label: "Italiano" ), // Italian
LanguageSwitcherData(value: "ja", label: "日本語" ), // Japanese
LanguageSwitcherData(value: "ka", label: "ქართული" ), // Georgian
LanguageSwitcherData(value: "kk", label: "Қазақша" ), // Kazakh
LanguageSwitcherData(value: "km", label: "ភាសាខ្មែរ" ), // Khmer
LanguageSwitcherData(value: "kn", label: "ಕನ್ನಡ" ), // Kannada
LanguageSwitcherData(value: "ko", label: "한국어" ), // Korean
LanguageSwitcherData(value: "ky", label: "Кыргызча" ), // Kyrgyz
LanguageSwitcherData(value: "lt", label: "Lietuvių" ), // Lithuanian
LanguageSwitcherData(value: "lv", label: "Latviešu" ), // Latvian
LanguageSwitcherData(value: "mk", label: "Македонски" ), // Macedonian
LanguageSwitcherData(value: "ml", label: "മലയാളം" ), // Malayalam
LanguageSwitcherData(value: "mr", label: "मराठी" ), // Marathi
LanguageSwitcherData(value: "ms", label: "Bahasa Melayu" ), // Malay
LanguageSwitcherData(value: "mt", label: "Malti" ), // Maltese
LanguageSwitcherData(value: "my", label: "မြန်မာ" ), // Burmese
LanguageSwitcherData(value: "nl", label: "Nederlands" ), // Dutch
LanguageSwitcherData(value: "no", label: "Norsk" ), // Norwegian
LanguageSwitcherData(value: "or", label: "ଓଡ଼ିଆ" ), // Odia
LanguageSwitcherData(value: "pa", label: "ਪੰਜਾਬੀ" ), // Punjabi
LanguageSwitcherData(value: "pl", label: "Polski" ), // Polish
LanguageSwitcherData(value: "pt", label: "Português" ), // Portuguese
LanguageSwitcherData(value: "ro", label: "Română" ), // Romanian
LanguageSwitcherData(value: "ru", label: "Русский" ), // Russian
LanguageSwitcherData(value: "sk", label: "Slovenčina" ), // Slovak
LanguageSwitcherData(value: "sl", label: "Slovenščina" ), // Slovenian
LanguageSwitcherData(value: "sq", label: "Shqip" ), // Albanian
LanguageSwitcherData(value: "sr", label: "Српски" ), // Serbian
LanguageSwitcherData(value: "sv", label: "Svenska" ), // Swedish
LanguageSwitcherData(value: "ta", label: "தமிழ்" ), // Tamil
LanguageSwitcherData(value: "te", label: "తెలుగు" ), // Telugu
LanguageSwitcherData(value: "th", label: "ไทย" ), // Thai
LanguageSwitcherData(value: "tr", label: "Türkçe" ), // Turkish
LanguageSwitcherData(value: "uk", label: "Українська" ), // Ukrainian
LanguageSwitcherData(value: "uz", label: "Oʻzbekcha" ), // Uzbek
LanguageSwitcherData(value: "vi", label: "Tiếng Việt" ), // Vietnamese
LanguageSwitcherData(value: "zh", label: "中文 (简体)" ), // Chinese (Simplified)
LanguageSwitcherData(value: "zh-Hant", label: "中文 (繁體)" ) // Chinese (Traditional)
]


0 comments on commit de158f7

Please sign in to comment.