mirror of
https://github.com/nextcloud/android.git
synced 2024-11-30 08:25:21 +03:00
use provide activity instead of calling getActivity, which might be null.
Signed-off-by: tobiaskaminsky <tobias@kaminsky.me>
This commit is contained in:
parent
4e2a019de6
commit
3d3fbe557a
1 changed files with 2 additions and 2 deletions
|
@ -167,7 +167,7 @@ public class ContactsBackupFragment extends FileFragment implements DatePickerDi
|
|||
view.findViewById(R.id.contacts_backup_now).getBackground()
|
||||
.setColorFilter(accentColor, PorterDuff.Mode.SRC_ATOP);
|
||||
|
||||
AppCompatButton chooseDate = (AppCompatButton) view.findViewById(R.id.contacts_datepicker);
|
||||
AppCompatButton chooseDate = view.findViewById(R.id.contacts_datepicker);
|
||||
chooseDate.getBackground().setColorFilter(accentColor, PorterDuff.Mode.SRC_ATOP);
|
||||
chooseDate.setTextColor(ThemeUtils.fontColor());
|
||||
|
||||
|
@ -203,7 +203,7 @@ public class ContactsBackupFragment extends FileFragment implements DatePickerDi
|
|||
@Override
|
||||
protected Boolean doInBackground(String... path) {
|
||||
FileDataStorageManager storageManager = new FileDataStorageManager(account,
|
||||
getActivity().getContentResolver());
|
||||
contactsPreferenceActivity.getContentResolver());
|
||||
|
||||
OCFile folder = storageManager.getFileByPath(path[0]);
|
||||
|
||||
|
|
Loading…
Reference in a new issue