title: Flutter Attempt to invoke virtual method 'boolean java.lang.String.equals(java.lang.Object)'
body: <p>Using flutter's plugin <strong>file_picker</strong>, runs smoothly till when you select a file, whenever i select a file, the entire app crashes, line in <em>pubspec.yaml</em> <code>file_picker: ^1.12.0</code> and flutter code is:</p>
  <pre><code>onTap: () async {
    File file = await FilePicker.getFilePath(type: FileType.video);
  },
  </code></pre>
  <p>This has been eating me alive and none of the solutions i found online have helped. The stacktrace is:</p>
  <pre><code>D/FilePickerDelegate(16658): Selected type video/*
  D/EGL_emulation(16658): eglMakeCurrent: 0x9f7462a0: ver 2 0 (tinfo 0x8fc0a3d0)
  D/FlutterView(16658): Detaching from a FlutterEngine: io.flutter.embedding.engine.FlutterEngine@c94b1b9
  I/FilePickerDelegate(16658): [SingleFilePick] File URI:content://com.android.providers.downloads.documents/document/40
  E/FilePickerUtils(16658): Getting for API 19 or abovecontent://com.android.providers.downloads.documents/document/40
  E/AndroidRuntime(16658): FATAL EXCEPTION: Thread-4
  E/AndroidRuntime(16658): Process: com.lulliezy.video, PID: 16658
  E/AndroidRuntime(16658): java.lang.NullPointerException: Attempt to invoke virtual method 'boolean java.lang.String.equals(java.lang.Object)' on a null object reference
  E/AndroidRuntime(16658):    at com.mr.flutter.plugin.filepicker.FilePickerDelegate$2.run(FilePickerDelegate.java:106)
  E/AndroidRuntime(16658):    at java.lang.Thread.run(Thread.java:761)
  E/FilePickerUtils(16658): Document URI
  E/FilePickerUtils(16658): Downloads External Document URI
  D/FlutterView(16658): Attaching to a FlutterEngine: io.flutter.embedding.engine.FlutterEngine@c94b1b9
  I/FilePickerDelegate(16658): Absolute file path:/storage/emulated/0/Download/videoplayback.mp4
  D/EGL_emulation(16658): eglCreateContext: 0xa3f05780: maj 2 min 0 rcv 2
  D/EGL_emulation(16658): eglMakeCurrent: 0xa3f05780: ver 2 0 (tinfo 0xa3f03200)
  D/EGL_emulation(16658): eglMakeCurrent: 0x9f7462a0: ver 2 0 (tinfo 0x8fc0a3d0)
  D/EGL_emulation(16658): eglMakeCurrent: 0xa3f05780: ver 2 0 (tinfo 0xa3f03200)
  E/Surface (16658): queueBuffer: error queuing buffer to SurfaceTexture, -19
  E/EGL_emulation(16658): tid 16675: swapBuffers(547): error 0x300d (EGL_BAD_SURFACE)
  D/EGL_emulation(16658): eglMakeCurrent: 0x9f7462a0: ver 2 0 (tinfo 0x8fc0a3d0)
  D/FlutterView(16658): Detaching from a FlutterEngine: io.flutter.embedding.engine.FlutterEngine@c94b1b9
  D/FlutterActivityAndFragmentDelegate(16658): Detaching FlutterEngine from the Activity that owns this Fragment.
  D/FlutterEngine(16658): Destroying.
  D/FlutterEnginePluginRegistry(16658): Destroying.
  </code></pre>
  <p>Any help on this would be highly appreciated.</p>
  <p>Also, am fairly new to Flutter/Dart, so please excuse my ignorance if any.</p>