diff --git a/app/build.gradle b/app/build.gradle index 21beb46..47879b9 100644 --- a/app/build.gradle +++ b/app/build.gradle @@ -24,11 +24,11 @@ android { } } compileOptions { - sourceCompatibility JavaVersion.VERSION_1_8 - targetCompatibility JavaVersion.VERSION_1_8 + sourceCompatibility JavaVersion.VERSION_11 + targetCompatibility JavaVersion.VERSION_11 } kotlinOptions { - jvmTarget = '1.8' + jvmTarget = '11' } } diff --git a/app/src/main/java/com/islam/appcentercicd/MainActivity.kt b/app/src/main/java/com/islam/appcentercicd/MainActivity.kt index 7fc1409..ca9132c 100644 --- a/app/src/main/java/com/islam/appcentercicd/MainActivity.kt +++ b/app/src/main/java/com/islam/appcentercicd/MainActivity.kt @@ -1,13 +1,18 @@ package com.islam.appcentercicd -import androidx.appcompat.app.AppCompatActivity import android.os.Bundle +import androidx.appcompat.app.AppCompatActivity +import com.microsoft.appcenter.AppCenter +import com.microsoft.appcenter.analytics.Analytics +import com.microsoft.appcenter.crashes.Crashes class MainActivity : AppCompatActivity() { override fun onCreate(savedInstanceState: Bundle?) { super.onCreate(savedInstanceState) setContentView(R.layout.activity_main) - AppCenter.start(getApplication(), "78a15f84-5697-4886-88c8-cd9cc3bcfaf2", - Analytics.class, Crashes.class); + AppCenter.start( + application, "78a15f84-5697-4886-88c8-cd9cc3bcfaf2", + Analytics::class.java, Crashes::class.java + ); } }