Fix issue #30
This commit is contained in:
parent
86d9ba930c
commit
54ffbe2e15
|
@ -856,15 +856,12 @@ public class PeertubeActivity extends AppCompatActivity implements CommentListAd
|
|||
} else if (itemId == R.id.action_share) {
|
||||
Intent sendIntent = new Intent(Intent.ACTION_SEND);
|
||||
sendIntent.putExtra(Intent.EXTRA_SUBJECT, getString(R.string.shared_via));
|
||||
String url;
|
||||
|
||||
url = peertube.getFiles().get(0).getFileDownloadUrl();
|
||||
boolean share_details = sharedpreferences.getBoolean(Helper.SET_SHARE_DETAILS, true);
|
||||
String extra_text;
|
||||
if (share_details) {
|
||||
extra_text = "@" + peertube.getAccount().getAcct();
|
||||
extra_text += "\r\n\r\n" + peertube.getName();
|
||||
extra_text += "\n\n\uD83D\uDD17 " + url + "\r\n-\n";
|
||||
extra_text += "\n\n\uD83D\uDD17 https://" + peertube.getChannel().getHost() + "/videos/watch/" + peertube.getUuid() + "\r\n-\n";
|
||||
final String contentToot;
|
||||
if (peertube.getDescription() != null) {
|
||||
if (Build.VERSION.SDK_INT >= Build.VERSION_CODES.N)
|
||||
|
@ -876,7 +873,7 @@ public class PeertubeActivity extends AppCompatActivity implements CommentListAd
|
|||
}
|
||||
extra_text += contentToot;
|
||||
} else {
|
||||
extra_text = url;
|
||||
extra_text = "https://" + peertube.getChannel().getHost() + "/videos/watch/" + peertube.getUuid();
|
||||
}
|
||||
sendIntent.putExtra(Intent.EXTRA_TEXT, extra_text);
|
||||
sendIntent.setType("text/plain");
|
||||
|
|
Loading…
Reference in New Issue