File tree Expand file tree Collapse file tree 1 file changed +2
-15
lines changed
packages/flutter_tools/gradle/src/main/kotlin Expand file tree Collapse file tree 1 file changed +2
-15
lines changed Original file line number Diff line number Diff line change @@ -155,7 +155,7 @@ object DependencyVersionChecker {
155155 val minSdkCheckTask =
156156 project.tasks.register(taskName) {
157157 doLast {
158- val minSdkVersion = getMinSdkVersion(project, it)
158+ val minSdkVersion = getMinSdkVersion(it)
159159 try {
160160 checkMinSdkVersion(minSdkVersion, project.rootDir.path, project.logger)
161161 } catch (e: DependencyValidationException ) {
@@ -180,20 +180,7 @@ object DependencyVersionChecker {
180180
181181 private fun generateMinSdkCheckTaskName (it : Variant ) = " ${FlutterPluginUtils .capitalize(it.name)}$MIN_SDK_CHECK_TASK_POSTFIX "
182182
183- private fun getMinSdkVersion (
184- project : Project ,
185- it : Variant
186- ): MinSdkVersion {
187- val agpVersion: AndroidPluginVersion ? = VersionFetcher .getAGPVersion(project)
188- // TODO(reidbaker): Remove version check as 8.3 is the minimum supported version.
189- // Keeping the check around so that users that bypass will get the error message and not
190- // a compile time error. See https://github.com/flutter/flutter/pull/171399
191- return if (agpVersion != null && agpVersion.major >= 8 && agpVersion.minor >= 1 ) {
192- MinSdkVersion (it.name, it.minSdk.apiLevel)
193- } else {
194- MinSdkVersion (it.name, it.minSdkVersion.apiLevel)
195- }
196- }
183+ private fun getMinSdkVersion (it : Variant ): MinSdkVersion = MinSdkVersion (it.name, it.minSdk.apiLevel)
197184
198185 @VisibleForTesting internal fun getErrorMessage (
199186 dependencyName : String ,
You can’t perform that action at this time.
0 commit comments