how to solve google authentication error when using passport.js

I am trying to impliment google authentication feature to my Node.js application using Passport.js middleware and google oAuth strategy when click the button after sometimes the user is created in database but page does not redirect to the home page

it’s redirect to authentication route and keep loading after sometimes user created in mongodb database but not redirect to the home