Commit fb9babe4 authored by Robert Hitt's avatar Robert Hitt
Browse files

Added leak checking stuff

parent 0c9f9814
......@@ -40,4 +40,7 @@ dependencies {
testCompile 'junit:junit:4.12'
compile 'com.jakewharton:butterknife:8.4.0'
apt 'com.jakewharton:butterknife-compiler:8.4.0'
debugCompile 'com.squareup.leakcanary:leakcanary-android:1.5'
releaseCompile 'com.squareup.leakcanary:leakcanary-android-no-op:1.5'
testCompile 'com.squareup.leakcanary:leakcanary-android-no-op:1.5'
}
......@@ -2,6 +2,8 @@ package srct.whatsopen;
import android.app.Application;
import com.squareup.leakcanary.LeakCanary;
import io.realm.Realm;
import io.realm.RealmConfiguration;
......@@ -11,6 +13,12 @@ public class MyApplication extends Application {
public void onCreate() {
super.onCreate();
// Set up LeakCanary for memory leak detection
if(LeakCanary.isInAnalyzerProcess(this)) {
return;
}
LeakCanary.install(this);
// Default Realm config. Might want to change this later
Realm.init(this);
RealmConfiguration realmConfig = new RealmConfiguration.Builder().build();
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment