antonioribeiro / google2fa

A One Time Password Authentication package, compatible with Google Authenticator.
MIT License
1.83k stars 199 forks source link

Call to undefined method PragmaRX\Google2FA\Google2FA::getQRCodeInline() #162

Closed Saqib-QA closed 3 years ago

Saqib-QA commented 3 years ago

I just installed this package on my local, using Laravel 7.28.3 followed the steps described at https://www.sitepoint.com/2fa-in-laravel-with-google-authenticator-get-secure/ and got the following error. Error Call to undefined method PragmaRX\Google2FA\Google2FA::getQRCodeInline() rechecked my code with repo, code is fine.

Saqib-QA commented 3 years ago

sorry

mfn commented 3 years ago

I think you created this on the wrong repo, I think this should be at https://github.com/antonioribeiro/google2fa-laravel (but it's easy to miss this I guess)

PragmaRX\Google2FA\Google2FA::getQRCodeInline()

This is supposed to reference the Facade alias, see https://github.com/antonioribeiro/google2fa-laravel#use-the-facade

HTH

antonioribeiro commented 3 years ago

Yeah, @mfn, got it right, @Saqib-QA , just follow examples on our readme, and you should be fine.