Skip to content

Commit

Permalink
Fix MediaPreview NPE.
Browse files Browse the repository at this point in the history
  • Loading branch information
greyson-signal committed Nov 27, 2018
1 parent 193d827 commit 8a1a47e
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion src/org/thoughtcrime/securesms/MediaPreviewActivity.java
Original file line number Diff line number Diff line change
Expand Up @@ -241,7 +241,7 @@ private void initializeResources() {

private void initializeObservers() {
viewModel.getPreviewData().observe(this, previewData -> {
if (previewData == null) {
if (previewData == null || mediaPager == null || mediaPager.getAdapter() == null) {
return;
}

Expand Down

0 comments on commit 8a1a47e

Please sign in to comment.