I am creating an application but it tells me that my code is obsolete?

1

What happens is that I copied this video ( link ) the code and everything I noticed is from 2017 and I knew that I could fail but then I tried it, I followed everything as I did but in the end when wanting to use the emulator it tells me this:

  

WARNING: Configuration 'compile' is obsolete and has been replaced   with 'implementation' and 'api'.

that I have 5 errors

    
asked by Erwin H 10.09.2018 в 00:05
source

1 answer

1

It's very simple, the only thing you have to do is that in app / build.gradle in the section dependencias you must change all your liberias that say compile and implement. I leave as an example my section dependencies.

dependencies {

    //TODO comienza con implementation antes decia compile
    implementation fileTree(dir: 'libs', include: ['*.jar'])
    implementation"org.jetbrains.kotlin:kotlin-stdlib-jdk7:$kotlin_version"

    //Support
    implementation 'com.android.support:appcompat-v7:28.0.0-rc01'
    implementation 'com.android.support.constraint:constraint-layout:1.1.3'

    //Firebase
    implementation 'com.google.firebase:firebase-core:16.0.3'
    implementation 'com.google.firebase:firebase-database:16.0.1'

    //Zxing
    implementation 'com.google.zxing:core:3.3.0'

    //Easy Permissions
    implementation 'pub.devrel:easypermissions:1.3.0'

    // Reactive
    implementation "io.reactivex.rxjava2:rxandroid:2.0.1"
    implementation "io.reactivex.rxjava2:rxkotlin:2.0.3"

    //itextPDF
    implementation 'com.itextpdf:itextpdf:5.0.6'
}

Additionally, add the following in your ResetPasswordActivity class

in the section imports

import erwinavendaomiguelgijon.gihac0m.R

About the problem of the emulator you could review this answer. link

    
answered by 10.09.2018 / 00:46
source