summaryrefslogtreecommitdiff
path: root/app/src/main/java/se/leap/bitmaskclient
diff options
context:
space:
mode:
authorcyBerta <cyberta@riseup.net>2019-07-12 17:56:24 +0200
committercyBerta <cyberta@riseup.net>2019-07-12 17:56:24 +0200
commit2979517d1401a42eedcadfbe33af4af02ef0afac (patch)
tree2a533d03bfe520b524e3aba4f3831c809421f48f /app/src/main/java/se/leap/bitmaskclient
parent2b649dbc89481a18318b0c1f4974ce3f650178e7 (diff)
fix shared preferences location for saving last used vpn profile
Diffstat (limited to 'app/src/main/java/se/leap/bitmaskclient')
-rw-r--r--app/src/main/java/se/leap/bitmaskclient/utils/PreferenceHelper.java4
1 files changed, 2 insertions, 2 deletions
diff --git a/app/src/main/java/se/leap/bitmaskclient/utils/PreferenceHelper.java b/app/src/main/java/se/leap/bitmaskclient/utils/PreferenceHelper.java
index 8c74ae0e..a52ee790 100644
--- a/app/src/main/java/se/leap/bitmaskclient/utils/PreferenceHelper.java
+++ b/app/src/main/java/se/leap/bitmaskclient/utils/PreferenceHelper.java
@@ -148,8 +148,8 @@ public class PreferenceHelper {
/**
* Sets the profile that is connected (to connect if the service restarts)
*/
- public static void setLastUsedVpnProfile(Context c, VpnProfile connectedProfile) {
- SharedPreferences prefs = Preferences.getDefaultSharedPreferences(c);
+ public static void setLastUsedVpnProfile(Context context, VpnProfile connectedProfile) {
+ SharedPreferences prefs = context.getSharedPreferences(SHARED_PREFERENCES, MODE_PRIVATE);
SharedPreferences.Editor prefsedit = prefs.edit();
prefsedit.putString(LAST_USED_PROFILE, connectedProfile.toJson());
prefsedit.apply();