Fixed crash when no sdcard installed
This commit is contained in:
parent
443eda1642
commit
4efd48a05d
@ -134,10 +134,12 @@ public class Configurations {
|
|||||||
|
|
||||||
public void save() {
|
public void save() {
|
||||||
try {
|
try {
|
||||||
|
if (file != null) {
|
||||||
FileWriter writer = new FileWriter(file);
|
FileWriter writer = new FileWriter(file);
|
||||||
new Gson().toJson(this, writer);
|
new Gson().toJson(this, writer);
|
||||||
writer.flush();
|
writer.flush();
|
||||||
writer.close();
|
writer.close();
|
||||||
|
}
|
||||||
} catch (IOException e) {
|
} catch (IOException e) {
|
||||||
Logger.logException(e);
|
Logger.logException(e);
|
||||||
}
|
}
|
||||||
|
Loading…
x
Reference in New Issue
Block a user