mirror of
https://github.com/moparisthebest/open-keychain
synced 2025-02-25 07:51:48 -05:00
Wrap EXTRA_REPLACEMENT_EXTRAS section so it only runs on Lollipop or greater
This commit is contained in:
parent
b06e7cd737
commit
6383d19dd3
@ -228,6 +228,7 @@ public class ViewKeyAdvShareFragment extends LoaderFragment implements
|
|||||||
|
|
||||||
// Bluetooth Share will convert text/plain sent via EXTRA_TEXT to HTML
|
// Bluetooth Share will convert text/plain sent via EXTRA_TEXT to HTML
|
||||||
// Add replacement extra to send a text/plain file instead.
|
// Add replacement extra to send a text/plain file instead.
|
||||||
|
if (Build.VERSION.SDK_INT >= Build.VERSION_CODES.LOLLIPOP) {
|
||||||
try {
|
try {
|
||||||
final File contentFile = new File(getActivity().getExternalCacheDir(),
|
final File contentFile = new File(getActivity().getExternalCacheDir(),
|
||||||
"key-" + KeyFormattingUtils.getShortKeyIdAsHexFromFingerprint(fingerprintData, false) +
|
"key-" + KeyFormattingUtils.getShortKeyIdAsHexFromFingerprint(fingerprintData, false) +
|
||||||
@ -271,6 +272,7 @@ public class ViewKeyAdvShareFragment extends LoaderFragment implements
|
|||||||
Log.e(Constants.TAG, "error creating temporary Bluetooth key share file!", e);
|
Log.e(Constants.TAG, "error creating temporary Bluetooth key share file!", e);
|
||||||
Notify.create(getActivity(), R.string.error_bluetooth_file, Notify.Style.ERROR).show();
|
Notify.create(getActivity(), R.string.error_bluetooth_file, Notify.Style.ERROR).show();
|
||||||
}
|
}
|
||||||
|
}
|
||||||
|
|
||||||
startActivity(shareChooser);
|
startActivity(shareChooser);
|
||||||
}
|
}
|
||||||
|
Loading…
x
Reference in New Issue
Block a user