Use setters in SearchInfo
This commit is contained in:
parent
29b639b454
commit
5d1c3b3fa2
|
@ -43,12 +43,12 @@ public class SearchInfo extends ListInfo<InfoItem> {
|
||||||
info.addError(e);
|
info.addError(e);
|
||||||
}
|
}
|
||||||
try {
|
try {
|
||||||
info.searchSuggestion = extractor.getSearchSuggestion();
|
info.setSearchSuggestion(extractor.getSearchSuggestion());
|
||||||
} catch (Exception e) {
|
} catch (Exception e) {
|
||||||
info.addError(e);
|
info.addError(e);
|
||||||
}
|
}
|
||||||
try {
|
try {
|
||||||
info.isCorrectedSearch = extractor.isCorrectedSearch();
|
info.setCorrectedSearch(extractor.isCorrectedSearch());
|
||||||
} catch (Exception e) {
|
} catch (Exception e) {
|
||||||
info.addError(e);
|
info.addError(e);
|
||||||
}
|
}
|
||||||
|
@ -80,4 +80,12 @@ public class SearchInfo extends ListInfo<InfoItem> {
|
||||||
public boolean isCorrectedSearch() {
|
public boolean isCorrectedSearch() {
|
||||||
return this.isCorrectedSearch;
|
return this.isCorrectedSearch;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
public void setCorrectedSearch(boolean correctedSearch) {
|
||||||
|
isCorrectedSearch = correctedSearch;
|
||||||
|
}
|
||||||
|
|
||||||
|
public void setSearchSuggestion(String searchSuggestion) {
|
||||||
|
this.searchSuggestion = searchSuggestion;
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|
|
@ -143,7 +143,7 @@ public class YoutubeMusicSearchExtractor extends SearchExtractor {
|
||||||
return false;
|
return false;
|
||||||
}
|
}
|
||||||
|
|
||||||
JsonObject showingResultsForRenderer = itemSectionRenderer.getArray("contents").getObject(0)
|
final JsonObject showingResultsForRenderer = itemSectionRenderer.getArray("contents").getObject(0)
|
||||||
.getObject("showingResultsForRenderer");
|
.getObject("showingResultsForRenderer");
|
||||||
return showingResultsForRenderer != null;
|
return showingResultsForRenderer != null;
|
||||||
}
|
}
|
||||||
|
|
Loading…
Reference in New Issue