From 24619ce00692fab621637080789fd85622af58bc Mon Sep 17 00:00:00 2001 From: Bartosz Przybylski Date: Tue, 21 Jun 2016 23:37:52 +0200 Subject: [PATCH] Review fixes --- .../owncloud/android/providers/DocumentsStorageProvider.java | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/src/com/owncloud/android/providers/DocumentsStorageProvider.java b/src/com/owncloud/android/providers/DocumentsStorageProvider.java index 85942dd5a84..8a8629d3cfa 100644 --- a/src/com/owncloud/android/providers/DocumentsStorageProvider.java +++ b/src/com/owncloud/android/providers/DocumentsStorageProvider.java @@ -70,7 +70,8 @@ public Cursor queryDocument(String documentId, String[] projection) throws FileN updateCurrentStorageManagerIfNeeded(docId); final FileCursor result = new FileCursor(projection); - result.addFile(mCurrentStorageManager.getFileById(docId)); + if (result != null) + result.addFile(mCurrentStorageManager.getFileById(docId)); return result; }