use constant / remove USER_INFO from issue reports
This commit is contained in:
parent
ccda46bef8
commit
965288344e
3 changed files with 5 additions and 4 deletions
|
@ -17,6 +17,7 @@ public class Constants {
|
|||
|
||||
protected static final int MIN_NEXTCLOUD_FILES_APP_VERSION_CODE = 30030052;
|
||||
|
||||
public static final String USER_INFO_STRING = "USER_INFO";
|
||||
|
||||
protected static boolean isNextCloud(SharedPreferences prefs) {
|
||||
int[] version = extractVersionNumberFromString(prefs.getString(Constants.NEWS_WEB_VERSION_NUMBER_STRING, ""));
|
||||
|
|
|
@ -75,6 +75,7 @@ import io.reactivex.disposables.Disposable;
|
|||
import io.reactivex.schedulers.Schedulers;
|
||||
import uk.co.deanwild.materialshowcaseview.MaterialShowcaseView;
|
||||
|
||||
import static de.luhmer.owncloudnewsreader.Constants.USER_INFO_STRING;
|
||||
import static de.luhmer.owncloudnewsreader.LoginDialogActivity.RESULT_LOGIN;
|
||||
|
||||
/**
|
||||
|
@ -339,8 +340,6 @@ public class NewsReaderListFragment extends Fragment implements OnCreateContextM
|
|||
.show();
|
||||
}
|
||||
|
||||
private static final String USER_INFO_STRING = "USER_INFO";
|
||||
|
||||
public void startAsyncTaskGetUserInfo() {
|
||||
mApi.getAPI().user()
|
||||
.subscribeOn(Schedulers.newThread())
|
||||
|
|
|
@ -38,6 +38,7 @@ import de.luhmer.owncloudnewsreader.helper.NewsFileUtils;
|
|||
import de.luhmer.owncloudnewsreader.helper.PostDelayHandler;
|
||||
|
||||
import static android.app.Activity.RESULT_OK;
|
||||
import static de.luhmer.owncloudnewsreader.Constants.USER_INFO_STRING;
|
||||
import static de.luhmer.owncloudnewsreader.LoginDialogActivity.RESULT_LOGIN;
|
||||
import static de.luhmer.owncloudnewsreader.SettingsActivity.CB_MARK_AS_READ_WHILE_SCROLLING_STRING;
|
||||
import static de.luhmer.owncloudnewsreader.SettingsActivity.CB_NAVIGATE_WITH_VOLUME_BUTTONS_STRING;
|
||||
|
@ -276,7 +277,7 @@ public class SettingsFragment extends PreferenceFragmentCompat {
|
|||
|
||||
|
||||
clearCachePref.setOnPreferenceClickListener(preference -> {
|
||||
mPrefs.edit().remove("USER_INFO").apply();
|
||||
mPrefs.edit().remove(USER_INFO_STRING).apply();
|
||||
checkForUnsycedChangesInDatabaseAndResetDatabase(prefFrag.getActivity());
|
||||
return true;
|
||||
});
|
||||
|
@ -374,7 +375,7 @@ public class SettingsFragment extends PreferenceFragmentCompat {
|
|||
|
||||
debugInfo += "\n\n---\n\n";
|
||||
|
||||
List<String> excludedSettings = Arrays.asList(EDT_USERNAME_STRING, EDT_PASSWORD_STRING, EDT_OWNCLOUDROOTPATH_STRING, Constants.LAST_UPDATE_NEW_ITEMS_COUNT_STRING);
|
||||
List<String> excludedSettings = Arrays.asList(EDT_USERNAME_STRING, EDT_PASSWORD_STRING, EDT_OWNCLOUDROOTPATH_STRING, Constants.LAST_UPDATE_NEW_ITEMS_COUNT_STRING, USER_INFO_STRING);
|
||||
Map<String, ?> allEntries = mPrefs.getAll();
|
||||
for (Map.Entry<String, ?> entry : allEntries.entrySet()) {
|
||||
String key =entry.getKey();
|
||||
|
|
Loading…
Reference in a new issue