Skip to content

Add ability to get resource from base localization when it absent in current#117

Open
loginoleg wants to merge 1 commit intomarmelroy:masterfrom
loginoleg:feature-base-substitution
Open

Add ability to get resource from base localization when it absent in current#117
loginoleg wants to merge 1 commit intomarmelroy:masterfrom
loginoleg:feature-base-substitution

Conversation

@loginoleg
Copy link

For example, there are Вase and French localizations with keys. In Вase we have English strings. French localization file missed "CANCEL_BUTTON" resource.

Base.lproj: 
"CANCEL_BUTTON" = "Cancel";
"OK_BUTTON" = "Okay";
fr.lproj:
"OK_BUTTON" = "Okay";

So, "CANCEL_BUTTON".localized() return key "CANCEL_BUTTON" when current localization is French. That's not so good.
With this fix, "CANCEL_BUTTON".localized() check to "CANCEL_BUTTON" resource in the Base table and return "Cancel".

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant