Fabric's Digits.getInstance() giving NullPointerException

694 views Asked by At

Digits.getInstance() giving NullPointerException

java.lang.NullPointerException: Attempt to invoke virtual method 'com.digits.sdk.android.DigitsClient com.digits.sdk.android.Digits.getDigitsClient()' on a null object reference

I implemented Digits like -

Fabric.with(this, new TwitterCore(authConfig), new Digits());
        mAuthCallback = new AuthCallback() {
            @Override
            public void success(DigitsSession session, String phoneNumber) {
                // Do something with the session
            }

            @Override
            public void failure(DigitsException exception) {
                // Do something on failure
            }
        };
1

There are 1 answers

0
mihirjoshi On BEST ANSWER

I just made it work. When you are using multiple SDKs you have to club them into a single statement.

Fabric.with(this, new Crashlytics(), new TwitterCore(authConfig), new Digits());