fix SP for long with string-ressource-id
This commit is contained in:
parent
d1aec1ff18
commit
4b063a7766
|
@ -65,8 +65,12 @@ public class SP {
|
|||
}
|
||||
|
||||
static public long getLong(int resourceID, Long defaultValue) {
|
||||
try {
|
||||
return sharedPreferences.getLong(MainApp.sResources.getString(resourceID), defaultValue);
|
||||
} catch (Exception e) {
|
||||
return SafeParse.stringToLong(sharedPreferences.getString(MainApp.sResources.getString(resourceID), defaultValue.toString()));
|
||||
}
|
||||
}
|
||||
|
||||
static public long getLong(String key, Long defaultValue) {
|
||||
try {
|
||||
|
|
Loading…
Reference in a new issue