Skip to content

Commit

Permalink
Merge pull request #309 from archie94/share_valid_trigger_files
Browse files Browse the repository at this point in the history
Share URIs for valid file / file paths only
  • Loading branch information
n8fr8 authored Jun 29, 2018
2 parents 61aadc4 + 85c60a5 commit f954729
Showing 1 changed file with 4 additions and 0 deletions.
4 changes: 4 additions & 0 deletions src/main/java/org/havenapp/main/ui/EventActivity.java
Original file line number Diff line number Diff line change
Expand Up @@ -156,6 +156,10 @@ private void shareEvent ()
//convert from paths to Android friendly Parcelable Uri's
for (EventTrigger trigger : mEvent.getEventTriggers())
{
// ignore triggers for which we do not have valid file/file-paths
if (trigger.getMimeType() == null || trigger.getPath() == null)
continue;

File fileIn = new File(trigger.getPath());
Uri u = Uri.fromFile(fileIn);
uris.add(u);
Expand Down

0 comments on commit f954729

Please sign in to comment.