无法连接到Firebase和应用程序崩溃

时间:2018-10-22 15:39:20

标签: android

我正在尝试连接到Android Studio 3.2.1中的firebase。应用implementation 'com.google.firebase:firebase-database:16.0.1:15.0.0'之后,firebase依赖关系已正确设置,并且在我删除15.0.0时,firebase依赖关系已断开连接。同样,当连接到手机(Android版本7.1.1,系统版本26.31.1)时,应用也会崩溃。

我该如何进行?

apply plugin: 'com.android.application'


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

implementation fileTree(dir: 'libs', include: ['*.jar'])

implementation 'com.android.support:appcompat-v7:27.1.1'
implementation 'com.android.support:customtabs:27.1.1'
implementation 'com.android.support:support-media-compat:27.1.1'
implementation 'com.android.support:support-v4:27.1.1'

implementation 'com.android.support.constraint:constraint-layout:1.1.3'
implementation 'com.google.firebase:firebase-core:16.0.4'


implementation 'com.google.firebase:firebase-database:16.0.3'
implementation 'com.google.android.gms:play-services-ads:17.0.0'
implementation 'com.google.android.gms:play-services-auth:16.0.1'
implementation 'com.google.firebase:firebase-messaging:17.3.4'
testImplementation 'junit:junit:4.12'
androidTestImplementation 'com.android.support.test:runner:1.0.2'
androidTestImplementation 'com.android.support.test.espresso:espresso-core:3.0.2'
implementation 'com.google.android.gms:play-services-maps:16.0.0'
implementation 'com.google.firebase:firebase-database:16.0.2'


implementation 'com.google.firebase:firebase-database:16.0.1'
implementation 'com.google.firebase:firebase-database:16.0.1:15.0.0'

0 个答案:

没有答案