title: java.lang.SecurityException: Permission Denial: opening provider com.android.providers.media.Media
body: <p>I am getting-</p>
  
  <pre><code>java.lang.SecurityException: Permission Denial: opening provider com.android.providers.media.MediaDocumentsProvider from ProcessRecord{f1d408f 5594:firebasejobscheduler.test.com.firbasejobschedulerdemo/u0a1227} (pid=5594, uid=11227) requires android.permission.MANAGE_DOCUMENTS or android.permission.MANAGE_DOCUMENTS
  </code></pre>
  
  <p>at</p>
  
  <pre><code> bm = MediaStore.Images.Media.getBitmap(context.getContentResolver(), uri);
  </code></pre>
  
  <p>I have checked <a href="https://stackoverflow.com/questions/19837358/android-kitkat-securityexception-when-trying-to-read-from-mediastore">this</a> post but not able to resolve it.How can i resolve this?</p>