package com.vsahin.moneycim;

import android.app.Activity;
import android.app.Application;

import com.vsahin.moneycim.Di.DaggerAppComponent;

import javax.inject.Inject;

import dagger.android.AndroidInjector;
import dagger.android.DispatchingAndroidInjector;
import dagger.android.HasActivityInjector;

/**
 * Created by Volkan Şahin on 17.08.2017.
 */

public class MoneycimApp extends Application implements HasActivityInjector {

    @Inject
    DispatchingAndroidInjector<Activity> dispatchingAndroidInjector;

    @Override
    public void onCreate() {
        super.onCreate();

        DaggerAppComponent
                .builder()
                .create(this)
                .inject(this);
    }

    @Override
    public AndroidInjector<Activity> activityInjector() {
        return dispatchingAndroidInjector;
    }
}

@@ -308,16 +308,66 @@
 jector;%0D
+%0Aimport dagger.android.support.DaggerApplication;%0D
 %0A%0D%0A/**%0D%0A
@@ -449,16 +449,22 @@
 extends 
+Dagger
 Applicat
@@ -471,446 +471,166 @@
 ion 
-implements HasActivityInjector %7B%0D%0A%0D%0A    @Inject%0D%0A    DispatchingAndroidInjector%3CActivity%3E dispatchingAndroidInjector;%0D%0A%0D%0A    @Override%0D%0A    public void onCreate() %7B%0D%0A        super.onCreate();%0D%0A%0D%0A        DaggerAppComponent%0D%0A                .builder()%0D%0A                .create(this)%0D%0A                .inject(this);%0D%0A    %7D%0D%0A%0D%0A    @Override%0D%0A    public AndroidInjector%3CActivity%3E activityInjector() %7B%0D%0A        return dispatchingAndroidInjector
+%7B%0D%0A    @Override%0D%0A    protected AndroidInjector%3C? extends DaggerApplication%3E applicationInjector() %7B%0D%0A        return DaggerAppComponent.builder().create(this)
 ;%0D%0A 

Extend Application from DaggerApplication class