From 2f56f7e4a4498454b1fe01bac9ef7487475bc736 Mon Sep 17 00:00:00 2001 From: "dependabot-preview[bot]" <27856297+dependabot-preview[bot]@users.noreply.github.com> Date: Sun, 2 Feb 2020 15:50:12 +0000 Subject: [PATCH] Bump dagger from 2.25.4 to 2.26 (#673) --- app/build.gradle | 2 +- .../io/github/wulkanowy/services/ServicesModule.kt | 5 ++--- .../github/wulkanowy/ui/modules/grade/GradeModule.kt | 5 ++--- .../github/wulkanowy/ui/modules/login/LoginModule.kt | 5 ++--- .../io/github/wulkanowy/ui/modules/main/MainModule.kt | 10 ++++------ .../wulkanowy/ui/modules/message/MessageModule.kt | 5 ++--- .../schoolandteachers/SchoolAndTeachersModule.kt | 5 ++--- 7 files changed, 15 insertions(+), 22 deletions(-) diff --git a/app/build.gradle b/app/build.gradle index 24306cd1..d621904c 100644 --- a/app/build.gradle +++ b/app/build.gradle @@ -112,7 +112,7 @@ play { ext { work_manager = "2.3.0" room = "2.2.3" - dagger = "2.25.4" + dagger = "2.26" chucker = "2.0.4" mockk = "1.9.2" } diff --git a/app/src/main/java/io/github/wulkanowy/services/ServicesModule.kt b/app/src/main/java/io/github/wulkanowy/services/ServicesModule.kt index 78bdbd8c..2ca55d2e 100644 --- a/app/src/main/java/io/github/wulkanowy/services/ServicesModule.kt +++ b/app/src/main/java/io/github/wulkanowy/services/ServicesModule.kt @@ -29,11 +29,10 @@ import javax.inject.Singleton @Suppress("unused") @AssistedModule -@Module(includes = [AssistedInject_ServicesModule::class, ServicesModule.Static::class]) +@Module(includes = [AssistedInject_ServicesModule::class]) abstract class ServicesModule { - @Module - object Static { + companion object { @Provides fun provideWorkManager(context: Context) = WorkManager.getInstance(context) diff --git a/app/src/main/java/io/github/wulkanowy/ui/modules/grade/GradeModule.kt b/app/src/main/java/io/github/wulkanowy/ui/modules/grade/GradeModule.kt index 6e6ca2d6..342f356c 100644 --- a/app/src/main/java/io/github/wulkanowy/ui/modules/grade/GradeModule.kt +++ b/app/src/main/java/io/github/wulkanowy/ui/modules/grade/GradeModule.kt @@ -11,11 +11,10 @@ import io.github.wulkanowy.ui.modules.grade.statistics.GradeStatisticsFragment import io.github.wulkanowy.ui.modules.grade.summary.GradeSummaryFragment @Suppress("unused") -@Module(includes = [GradeModule.Static::class]) +@Module abstract class GradeModule { - @Module - object Static { + companion object { @PerFragment @Provides diff --git a/app/src/main/java/io/github/wulkanowy/ui/modules/login/LoginModule.kt b/app/src/main/java/io/github/wulkanowy/ui/modules/login/LoginModule.kt index 28339a46..6b5d5aef 100644 --- a/app/src/main/java/io/github/wulkanowy/ui/modules/login/LoginModule.kt +++ b/app/src/main/java/io/github/wulkanowy/ui/modules/login/LoginModule.kt @@ -12,11 +12,10 @@ import io.github.wulkanowy.ui.modules.login.studentselect.LoginStudentSelectFrag import io.github.wulkanowy.ui.modules.login.symbol.LoginSymbolFragment @Suppress("unused") -@Module(includes = [LoginModule.Static::class]) +@Module internal abstract class LoginModule { - @Module - object Static { + companion object { @PerActivity @Provides diff --git a/app/src/main/java/io/github/wulkanowy/ui/modules/main/MainModule.kt b/app/src/main/java/io/github/wulkanowy/ui/modules/main/MainModule.kt index 50e5896f..a16e6320 100644 --- a/app/src/main/java/io/github/wulkanowy/ui/modules/main/MainModule.kt +++ b/app/src/main/java/io/github/wulkanowy/ui/modules/main/MainModule.kt @@ -35,16 +35,14 @@ import io.github.wulkanowy.ui.modules.timetable.TimetableFragment import io.github.wulkanowy.ui.modules.timetable.completed.CompletedLessonsFragment @Suppress("unused") -@Module(includes = [MainModule.Static::class]) +@Module abstract class MainModule { - @Module - object Static { + companion object { @Provides - fun provideFragNavController(activity: MainActivity): FragNavController { - return FragNavController(activity.supportFragmentManager, R.id.mainFragmentContainer) - } + fun provideFragNavController(activity: MainActivity) = + FragNavController(activity.supportFragmentManager, R.id.mainFragmentContainer) //In activities must be injected as Lazy @Provides diff --git a/app/src/main/java/io/github/wulkanowy/ui/modules/message/MessageModule.kt b/app/src/main/java/io/github/wulkanowy/ui/modules/message/MessageModule.kt index b2521902..bf795020 100644 --- a/app/src/main/java/io/github/wulkanowy/ui/modules/message/MessageModule.kt +++ b/app/src/main/java/io/github/wulkanowy/ui/modules/message/MessageModule.kt @@ -9,11 +9,10 @@ import io.github.wulkanowy.ui.base.BaseFragmentPagerAdapter import io.github.wulkanowy.ui.modules.message.tab.MessageTabFragment @Suppress("unused") -@Module(includes = [MessageModule.Static::class]) +@Module abstract class MessageModule { - @Module - object Static { + companion object { @PerFragment @Provides diff --git a/app/src/main/java/io/github/wulkanowy/ui/modules/schoolandteachers/SchoolAndTeachersModule.kt b/app/src/main/java/io/github/wulkanowy/ui/modules/schoolandteachers/SchoolAndTeachersModule.kt index 62803a28..2087b0b4 100644 --- a/app/src/main/java/io/github/wulkanowy/ui/modules/schoolandteachers/SchoolAndTeachersModule.kt +++ b/app/src/main/java/io/github/wulkanowy/ui/modules/schoolandteachers/SchoolAndTeachersModule.kt @@ -10,11 +10,10 @@ import io.github.wulkanowy.ui.modules.schoolandteachers.school.SchoolFragment import io.github.wulkanowy.ui.modules.schoolandteachers.teacher.TeacherFragment @Suppress("unused") -@Module(includes = [SchoolAndTeachersModule.Static::class]) +@Module abstract class SchoolAndTeachersModule { - @Module - object Static { + companion object { @PerFragment @Provides