buildTypes cannot be applied to groovy.lang.Closure

前端 未结 19 2229
故里飘歌
故里飘歌 2020-11-27 11:31

I\'m getting this warning in my project gradle file:

Warning:(16, 5) \'buildTypes\' cannot be applied to \'(groovy.lang.Closure< com.android.build.

19条回答
  •  鱼传尺愫
    2020-11-27 12:06

    If none of the above options work, then do the Following

    1. Change the project to Project perspective in the "Project Explorer".
    2. Delete .gradle and build folders.
    3. Click File -> Invalidate Caches / Restart... -> Invalidate and Restart
    4. Now its working, happy coding.

提交回复
热议问题