From bf6b857a3eeb47bbc4c9cad62cfad20e88461e9c Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Rafa=C5=82=20Borcz?= Date: Sat, 18 May 2019 00:22:07 +0200 Subject: [PATCH] Fix null returns in widgets (#340) --- .../ui/modules/luckynumberwidget/LuckyNumberWidgetProvider.kt | 2 +- .../ui/modules/timetablewidget/TimetableWidgetProvider.kt | 2 +- build.gradle | 2 +- 3 files changed, 3 insertions(+), 3 deletions(-) diff --git a/app/src/main/java/io/github/wulkanowy/ui/modules/luckynumberwidget/LuckyNumberWidgetProvider.kt b/app/src/main/java/io/github/wulkanowy/ui/modules/luckynumberwidget/LuckyNumberWidgetProvider.kt index cbf3b63c..51285969 100644 --- a/app/src/main/java/io/github/wulkanowy/ui/modules/luckynumberwidget/LuckyNumberWidgetProvider.kt +++ b/app/src/main/java/io/github/wulkanowy/ui/modules/luckynumberwidget/LuckyNumberWidgetProvider.kt @@ -104,7 +104,7 @@ class LuckyNumberWidgetProvider : BroadcastReceiver() { .toMaybe() .doOnSuccess { sharedPref.putLong(getStudentWidgetKey(appWidgetId), it.id) } } - else -> null + else -> Maybe.empty() } } } diff --git a/app/src/main/java/io/github/wulkanowy/ui/modules/timetablewidget/TimetableWidgetProvider.kt b/app/src/main/java/io/github/wulkanowy/ui/modules/timetablewidget/TimetableWidgetProvider.kt index 2b748760..9b35e5ca 100644 --- a/app/src/main/java/io/github/wulkanowy/ui/modules/timetablewidget/TimetableWidgetProvider.kt +++ b/app/src/main/java/io/github/wulkanowy/ui/modules/timetablewidget/TimetableWidgetProvider.kt @@ -165,7 +165,7 @@ class TimetableWidgetProvider : BroadcastReceiver() { .toMaybe() .doOnSuccess { sharedPref.putLong(getStudentWidgetKey(appWidgetId), it.id) } } - else -> null + else -> Maybe.empty() } } } diff --git a/build.gradle b/build.gradle index ac6bde63..1321c5f4 100644 --- a/build.gradle +++ b/build.gradle @@ -9,7 +9,7 @@ buildscript { } dependencies { classpath "org.jetbrains.kotlin:kotlin-gradle-plugin:$kotlin_version" - classpath 'com.android.tools.build:gradle:3.4.0' + classpath 'com.android.tools.build:gradle:3.4.1' classpath 'com.google.gms:google-services:4.2.0' classpath "io.fabric.tools:gradle:1.28.1" classpath "com.github.triplet.gradle:play-publisher:2.2.0"