fix check for articleId

This commit is contained in:
Chumva 2018-05-29 15:28:38 +03:00
parent fd16da1f81
commit 5167a076fe

View file

@ -199,7 +199,7 @@ public class WikivoyageExploreActivity extends TabActivity implements DownloadEv
String selectedLang = data.getQueryParameter("lang"); String selectedLang = data.getQueryParameter("lang");
if (!Algorithms.isEmpty(title) && !Algorithms.isEmpty(selectedLang)) { if (!Algorithms.isEmpty(title) && !Algorithms.isEmpty(selectedLang)) {
long articleId = app.getTravelDbHelper().getArticleId(title, selectedLang); long articleId = app.getTravelDbHelper().getArticleId(title, selectedLang);
if (articleId != -1) { if (articleId != 0) {
WikivoyageArticleDialogFragment.showInstance(app, getSupportFragmentManager(), articleId, selectedLang); WikivoyageArticleDialogFragment.showInstance(app, getSupportFragmentManager(), articleId, selectedLang);
} }
} }