php - laravel socialite error when user cancels -


i'm creating laravel 5 app, has social authentication inbound, have code user, register or log in in case user exists, works fine. issue when user not agreed login social provider app(eg, press cancel button), knows how handle that.

now if press cancel button on social login window throws 400 client error.

thanks in advance

you can use try-catch. move login/registration code inside try block & inside catch block, redirect user login page & show appropriate message


Comments

Popular posts from this blog

ruby - Trying to change last to "x"s to 23 -

jquery - Clone last and append item to closest class -

css - Can I use the :after pseudo-element on an input field? -