Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Registration Error #11

Open
Pratip009 opened this issue Nov 22, 2023 · 2 comments
Open

Registration Error #11

Pratip009 opened this issue Nov 22, 2023 · 2 comments

Comments

@Pratip009
Copy link

Error: Please Login to access this resource
at C:\Users\prati\OneDrive\Desktop\my docs\book\backend\middleWare\auth.js:10:17
at C:\Users\prati\OneDrive\Desktop\my docs\book\backend\middleWare\asyncWrapper.js:3:19
at Layer.handle [as handle_request] (C:\Users\prati\OneDrive\Desktop\my docs\book\node_modules\express\lib\router\layer.js:95:5)
at next (C:\Users\prati\OneDrive\Desktop\my docs\book\node_modules\express\lib\router\route.js:144:13)
at Route.dispatch (C:\Users\prati\OneDrive\Desktop\my docs\book\node_modules\express\lib\router\route.js:114:3)
at Layer.handle [as handle_request] (C:\Users\prati\OneDrive\Desktop\my docs\book\node_modules\express\lib\router\layer.js:95:5)
at C:\Users\prati\OneDrive\Desktop\my docs\book\node_modules\express\lib\router\index.js:284:15
at Function.process_params (C:\Users\prati\OneDrive\Desktop\my docs\book\node_modules\express\lib\router\index.js:346:12)
at next (C:\Users\prati\OneDrive\Desktop\my docs\book\node_modules\express\lib\router\index.js:280:10)
at Function.handle (C:\Users\prati\OneDrive\Desktop\my docs\book\node_modules\express\lib\router\index.js:175:3)
[object Object]

on console failed to load resource: the server responded with a status of 500(Internal Server Error)

@MehraDevesh2022
Copy link
Owner

Hi @Pratip009,

Thank you for reporting the "Registration Error #11" issue. I appreciate your diligence in troubleshooting.

I'd like to assist further. It's worth noting that the code is working seamlessly on my local machine and in the production environment where I've hosted it. However, it seems Pratip is encountering an error.

To help us pinpoint the issue, could you please provide the following details?

  1. Code Details:

    • Share the relevant parts of auth.js (especially around line 10) and asyncWrapper.js.
  2. User Authentication:

    • Confirm if the user is logged in before accessing the resource. Any insights into the login process would be helpful.
  3. Middleware Order:

    • Share the order of middleware in your application. Ensure authentication middleware is applied before accessing the protected resource.
  4. Server Logs:

    • Check your server logs for detailed error information. Share any relevant error stack trace or messages.

This will help us understand the issue better and provide a more accurate solution. Thanks!

@MadihaAmjad
Copy link

i also face same issue

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants