Skip to content

Commit

Permalink
perf: localize Bing phonetic string
Browse files Browse the repository at this point in the history
  • Loading branch information
tisfeng committed Dec 17, 2023
1 parent fb06d85 commit a17f038
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion Easydict/Feature/Service/Bing/EZBingService.m
Original file line number Diff line number Diff line change
Expand Up @@ -379,7 +379,7 @@ - (void)parseBingDictTranslate:(NSDictionary *)json word:(NSString *)word comple
EZWordPhonetic *phonetic = [EZWordPhonetic new];
phonetic.word = word;
phonetic.language = EZLanguageEnglish;
phonetic.name = [name isEqualToString:@"US"] ? @"" : @"";
phonetic.name = [name isEqualToString:@"US"] ? NSLocalizedString(@"us_phonetic", nil) : NSLocalizedString(@"uk_phonetic", nil);
phonetic.value = fragments.firstObject[@"text"];
phonetic.speakURL = [name isEqualToString:@"US"] ? usAudioUrl : [usAudioUrl stringByReplacingOccurrencesOfString:@"tom" withString:@"george"];
phonetic.accent = name;
Expand Down

0 comments on commit a17f038

Please sign in to comment.