mirror of
https://github.com/Helium314/HeliBoard.git
synced 2025-05-14 14:02:44 +00:00
remove attempt to find non-existing fallback dictionary
This commit is contained in:
parent
efb54c7573
commit
25b1c628e3
1 changed files with 4 additions and 11 deletions
|
@ -283,16 +283,9 @@ final public class BinaryDictionaryGetter {
|
|||
|
||||
if (!foundMainDict && dictPackSettings.isWordListActive(mainDictId)) {
|
||||
final File dict = loadDictionaryFromAssets(locale.toString(), context, weakMatchAcceptable);
|
||||
final AssetFileAddress fallbackAsset;
|
||||
if (dict == null) {
|
||||
// fall back to the old way (maybe remove? will not work if files are compressed)
|
||||
final int fallbackResId =
|
||||
DictionaryInfoUtils.getMainDictionaryResourceId(context.getResources(), locale);
|
||||
fallbackAsset = loadFallbackResource(context, fallbackResId);
|
||||
} else {
|
||||
fallbackAsset = AssetFileAddress.makeFromFileName(dict.getPath());
|
||||
}
|
||||
if (null != fallbackAsset) {
|
||||
if (dict != null) {
|
||||
final AssetFileAddress fallbackAsset = AssetFileAddress.makeFromFileName(dict.getPath());
|
||||
if (fallbackAsset != null)
|
||||
fileList.add(fallbackAsset);
|
||||
}
|
||||
}
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue