Remove a useless variable (A20)
Change-Id: Ifc37462f5243563693c8cd7cbeb401ff054daa52main
parent
739683dcfb
commit
4d5e7235c5
|
@ -230,19 +230,17 @@ public class Suggest {
|
||||||
if (isCorrectionEnabled) {
|
if (isCorrectionEnabled) {
|
||||||
final SuggestedWordInfo bestSuggestion = suggestionsSet.isEmpty()
|
final SuggestedWordInfo bestSuggestion = suggestionsSet.isEmpty()
|
||||||
? null : suggestionsSet.first();
|
? null : suggestionsSet.first();
|
||||||
final CharSequence autoCorrection;
|
|
||||||
if (null != whitelistedWord) {
|
if (null != whitelistedWord) {
|
||||||
autoCorrection = whitelistedWord;
|
hasAutoCorrection = true;
|
||||||
} else if (!AutoCorrection.isWhitelistedOrNotAWord(
|
} else if (!AutoCorrection.isWhitelistedOrNotAWord(
|
||||||
mDictionaries, consideredWord, false)) {
|
mDictionaries, consideredWord, false)) {
|
||||||
autoCorrection = consideredWord;
|
hasAutoCorrection = true;
|
||||||
} else if (AutoCorrection.hasAutoCorrectionForBinaryDictionary(bestSuggestion,
|
} else if (AutoCorrection.hasAutoCorrectionForBinaryDictionary(bestSuggestion,
|
||||||
consideredWord, mAutoCorrectionThreshold)) {
|
consideredWord, mAutoCorrectionThreshold)) {
|
||||||
autoCorrection = bestSuggestion.mWord;
|
hasAutoCorrection = true;
|
||||||
} else {
|
} else {
|
||||||
autoCorrection = null;
|
hasAutoCorrection = false;
|
||||||
}
|
}
|
||||||
hasAutoCorrection = (null != autoCorrection);
|
|
||||||
} else {
|
} else {
|
||||||
hasAutoCorrection = false;
|
hasAutoCorrection = false;
|
||||||
}
|
}
|
||||||
|
|
Loading…
Reference in New Issue