fixed send_multiple share intent with empty extras. fixes #3512

This commit is contained in:
Daniel Gultsch 2019-08-05 21:32:20 +02:00
parent 238df77a1e
commit 011bdd8ef6
1 changed files with 3 additions and 1 deletions

View File

@ -12,6 +12,7 @@ import android.view.MenuItem;
import android.widget.Toast;
import java.util.ArrayList;
import java.util.Collections;
import java.util.List;
import eu.siacs.conversations.Config;
@ -142,7 +143,8 @@ public class ShareWithActivity extends XmppActivity implements XmppConnectionSer
this.share.text = text;
}
} else if (Intent.ACTION_SEND_MULTIPLE.equals(action)) {
this.share.uris = intent.getParcelableArrayListExtra(Intent.EXTRA_STREAM);
final ArrayList<Uri> uris = intent.getParcelableArrayListExtra(Intent.EXTRA_STREAM);
this.share.uris = uris == null ? new ArrayList<>() : uris;
}
if (xmppConnectionServiceBound) {
xmppConnectionService.populateWithOrderedConversations(mConversations, this.share.uris.size() == 0, false);