diff --git a/src/org/thoughtcrime/securesms/database/ApnDatabase.java b/src/org/thoughtcrime/securesms/database/ApnDatabase.java index b95b5837f2..a136ceac4f 100644 --- a/src/org/thoughtcrime/securesms/database/ApnDatabase.java +++ b/src/org/thoughtcrime/securesms/database/ApnDatabase.java @@ -73,7 +73,7 @@ public class ApnDatabase { private static ApnDatabase instance = null; public synchronized static ApnDatabase getInstance(Context context) throws IOException { - if (instance == null) instance = new ApnDatabase(context); + if (instance == null) instance = new ApnDatabase(context.getApplicationContext()); return instance; } diff --git a/src/org/thoughtcrime/securesms/database/TextSecureDirectory.java b/src/org/thoughtcrime/securesms/database/TextSecureDirectory.java index 61c7173d1c..9e914ad288 100644 --- a/src/org/thoughtcrime/securesms/database/TextSecureDirectory.java +++ b/src/org/thoughtcrime/securesms/database/TextSecureDirectory.java @@ -47,7 +47,7 @@ public class TextSecureDirectory { if (instance == null) { synchronized (instanceLock) { if (instance == null) { - instance = new TextSecureDirectory(context); + instance = new TextSecureDirectory(context.getApplicationContext()); } } }