mirror of
https://github.com/nextcloud/android.git
synced 2024-11-22 21:25:35 +03:00
spotbugs: remove redundant null checks
Signed-off-by: Andy Scherzinger <info@andy-scherzinger.de>
This commit is contained in:
parent
0a9e79988a
commit
2c30e5e9f7
2 changed files with 4 additions and 10 deletions
|
@ -379,10 +379,7 @@ public class ShareFileFragment extends Fragment implements ShareUserListAdapter.
|
|||
@Override
|
||||
public void onClick(View expirationView) {
|
||||
if (mPublicShare != null && mPublicShare.getExpirationDate() > 0) {
|
||||
long chosenDateInMillis = -1;
|
||||
if (mPublicShare != null) {
|
||||
chosenDateInMillis = mPublicShare.getExpirationDate();
|
||||
}
|
||||
long chosenDateInMillis = mPublicShare.getExpirationDate();
|
||||
ExpirationDatePickerDialogFragment dialog =
|
||||
ExpirationDatePickerDialogFragment.newInstance(mFile, chosenDateInMillis);
|
||||
dialog.show(
|
||||
|
|
|
@ -718,12 +718,9 @@ public class FileOperationsHelper {
|
|||
|
||||
OCCapability capability = mFileActivity.getStorageManager().getCapability(mFileActivity.getAccount().name);
|
||||
SendShareDialog mSendShareDialog;
|
||||
if (capability != null) {
|
||||
|
||||
mSendShareDialog = SendShareDialog.newInstance(file, hideNcSharingOptions,
|
||||
capability.getFilesSharingPublicPasswordEnforced().isTrue());
|
||||
} else {
|
||||
mSendShareDialog = SendShareDialog.newInstance(file, hideNcSharingOptions, false);
|
||||
}
|
||||
mSendShareDialog.setFileOperationsHelper(this);
|
||||
mSendShareDialog.show(ft, "TAG_SEND_SHARE_DIALOG");
|
||||
}
|
||||
|
|
Loading…
Reference in a new issue