Closed tisfeng closed 5 months ago
Since refactoring startQuery:
, we don't need to call prehandleQueryTextLanguage:
method manually anymore.
- (void)startQuery:(EZQueryModel *)queryModel
completion:(void (^)(EZQueryResult *result, NSError *_Nullable error))completion {
NSString *queryText = queryModel.queryText;
EZLanguage from = queryModel.queryFromLanguage;
EZLanguage to = queryModel.queryTargetLanguage;
if ([self prehandleQueryTextLanguage:queryText
from:from
to:to
completion:completion]) {
return;
}
[self translate:queryText from:from to:to completion:completion];
}
I plan to release a small fix update tonight or tomorrow.
We need to speed up the Swift refactoring and turn it from an objc project into a Swift project.
Next, in order to better add new features later, I plan to rewrite the code related to the query service (excluding the services themselves), the previous code was a bit ugly, when we refactor it later, we should try our best to optimize it, making it easier to expand.
Fix https://github.com/tisfeng/Easydict/issues/421