title: Camera doesn't work for android 7.0
body: <p><strong><em>I'm getting: android.os.FileUriExposedException.</em></strong></p>
  
  <blockquote>
    <p>When targeting Android N, file:// URIs are not allowed anymore. I know
    We should use content:// URIs instead. However, my app needs file for
    both image and video. Any ideas?</p>
  </blockquote>
  
  <pre><code>  mMediaUri = Uri.fromFile(new File(AppHelper.getDirectoryPath(),AppHelper.getFileName() + ".jpeg"));
  
    Intent iCamera = new Intent(MediaStore.ACTION_IMAGE_CAPTURE);
    iCamera.putExtra(MediaStore.EXTRA_OUTPUT, mMediaUri);
    startActivityForResult(iCamera, Constants.INTENT_CALL.CAPTURE_IMAGE);
  </code></pre>
  
  <p><strong>and onActivityResult</strong></p>
  
  <pre><code>case Constants.INTENT_CALL.CAPTURE_IMAGE:
  String filePath=SiliCompressor.with(getActivity()).compress(mMediaUri.toString(), true);
  </code></pre>
  
  <blockquote>
    <p>Please add sample code...if Available.</p>
  </blockquote>