File tree Expand file tree Collapse file tree
src/main/java/in/hridayan/ashell/core/di Expand file tree Collapse file tree Original file line number Diff line number Diff line change 1717 uses : actions/setup-java@v3
1818 with :
1919 distribution : ' temurin'
20- java-version : ' 21 '
20+ java-version : ' 17 '
2121
2222 - name : Set up Android SDK
2323 uses : android-actions/setup-android@v3
Original file line number Diff line number Diff line change 1919 uses : actions/setup-java@v3
2020 with :
2121 distribution : ' temurin'
22- java-version : ' 21 '
22+ java-version : ' 17 '
2323
2424 - name : Set up Android SDK
2525 uses : android-actions/setup-android@v3
Original file line number Diff line number Diff line change @@ -30,8 +30,8 @@ android {
3030 }
3131
3232 compileOptions {
33- sourceCompatibility = JavaVersion .VERSION_21
34- targetCompatibility = JavaVersion .VERSION_21
33+ sourceCompatibility = JavaVersion .VERSION_17
34+ targetCompatibility = JavaVersion .VERSION_17
3535 }
3636}
3737
Original file line number Diff line number Diff line change 1+ import org.jetbrains.kotlin.gradle.dsl.JvmTarget
2+
13plugins {
24 alias(libs.plugins.android.application)
35 alias(libs.plugins.kotlin.android)
@@ -73,12 +75,14 @@ android {
7375 }
7476 }
7577 compileOptions {
76- sourceCompatibility = JavaVersion .VERSION_21
77- targetCompatibility = JavaVersion .VERSION_21
78+ sourceCompatibility = JavaVersion .VERSION_17
79+ targetCompatibility = JavaVersion .VERSION_17
7880 }
7981
8082 kotlin {
81- jvmToolchain(21 )
83+ compilerOptions {
84+ jvmTarget.set(JvmTarget .JVM_17 )
85+ }
8286 }
8387
8488 buildFeatures {
Original file line number Diff line number Diff line change 764764 id =" TrustAllX509TrustManager"
765765 message =" `checkClientTrusted` is empty, which could cause insecure network traffic due to trusting arbitrary TLS/SSL certificates presented by peers" >
766766 <location
767- file =" $GRADLE_USER_HOME/caches/9.0.0/transforms/15afd18ac19cf6a97530d48e5a425862 /transformed/out/jars/classes.jar" />
767+ file =" $GRADLE_USER_HOME/caches/9.0.0/transforms/652daaca518ddedc439d3bc6f410bd1c /transformed/out/jars/classes.jar" />
768768 </issue >
769769
770770 <issue
771771 id =" TrustAllX509TrustManager"
772772 message =" `checkServerTrusted` is empty, which could cause insecure network traffic due to trusting arbitrary TLS/SSL certificates presented by peers" >
773773 <location
774- file =" $GRADLE_USER_HOME/caches/9.0.0/transforms/15afd18ac19cf6a97530d48e5a425862 /transformed/out/jars/classes.jar" />
774+ file =" $GRADLE_USER_HOME/caches/9.0.0/transforms/652daaca518ddedc439d3bc6f410bd1c /transformed/out/jars/classes.jar" />
775775 </issue >
776776
777777 <issue
Original file line number Diff line number Diff line change @@ -33,7 +33,9 @@ object DatabaseModule {
3333 @Provides
3434 @Singleton
3535 fun provideDatabase (@ApplicationContext context : Context ): CommandDatabase {
36- return Room .databaseBuilder(
36+ lateinit var database: CommandDatabase
37+
38+ database = Room .databaseBuilder(
3739 context,
3840 CommandDatabase ::class .java,
3941 " command_database"
@@ -43,20 +45,14 @@ object DatabaseModule {
4345 override fun onCreate (db : SupportSQLiteDatabase ) {
4446 super .onCreate(db)
4547 CoroutineScope (Dispatchers .IO ).launch {
46- val database = Room .databaseBuilder(
47- context,
48- CommandDatabase ::class .java,
49- " command_database"
50- )
51- .addTypeConverter(StringListConverter ())
52- .build()
53-
5448 database.commandDao().insertAllCommands(preloadedCommands)
5549 }
5650 }
5751 })
5852 .fallbackToDestructiveMigration(false )
5953 .build()
54+
55+ return database
6056 }
6157
6258
Original file line number Diff line number Diff line change @@ -34,8 +34,8 @@ android {
3434 }
3535
3636 compileOptions {
37- sourceCompatibility = JavaVersion .VERSION_21
38- targetCompatibility = JavaVersion .VERSION_21
37+ sourceCompatibility = JavaVersion .VERSION_17
38+ targetCompatibility = JavaVersion .VERSION_17
3939 }
4040
4141 publishing {
You can’t perform that action at this time.
0 commit comments