Could not find method android() for arguments org.gradle.api.Project

前端 未结 4 772
-上瘾入骨i
-上瘾入骨i 2021-02-13 14:20

Getting a bug, when I try to compile my project in studio , i have search quite a bit with no real solution to it

Error:(17, 0) Could not find method android() for argu

4条回答
  •  悲&欢浪女
    2021-02-13 15:24

    I had same problem if your android block is in module's build.gradle and use google services, just add these 2 lines before android block:

    apply plugin: 'com.android.application'
    apply plugin: 'com.google.gms.google-services'

提交回复
热议问题