Skip to content

Commit

Permalink
Merge pull request #5870 from wordpress-mobile/issue/5867-reader-sear…
Browse files Browse the repository at this point in the history
…ch-fragment-crash

Fix #5867: make sure the query passed to the search service is not null
daniloercoli authored May 11, 2017
2 parents 37056b3 + 0fd5208 commit 79d8a97
Showing 1 changed file with 2 additions and 1 deletion.
Original file line number Diff line number Diff line change
@@ -19,6 +19,7 @@
import org.wordpress.android.ui.reader.ReaderEvents;
import org.wordpress.android.ui.reader.utils.ReaderUtils;
import org.wordpress.android.util.AppLog;
import org.wordpress.android.util.StringUtils;
import org.wordpress.android.util.UrlUtils;

import de.greenrobot.event.EventBus;
@@ -69,7 +70,7 @@ public int onStartCommand(Intent intent, int flags, int startId) {
return START_NOT_STICKY;
}

String query = intent.getStringExtra(ARG_QUERY);
String query = StringUtils.notNullStr(intent.getStringExtra(ARG_QUERY));
int offset = intent.getIntExtra(ARG_OFFSET, 0);
startSearch(query, offset);

0 comments on commit 79d8a97

Please sign in to comment.