Skip to content

TypeError: Cannot read property 'authorization' of undefined #7

@unionolivia

Description

@unionolivia

Please this is the response i receive on trying to submit on localhost:3000/new-event when a user has login. Is anything wrong with the 'authorization' in /server/middlewares/authenticate.js.
Please help me out.

TypeError: Cannot read property 'authorization' of undefined
at exports.default (/home/union/onegram/server/middlewares/authenticate.js:9:33)
at Layer.handle [as handle_request] (/home/union/onegram/node_modules/express/lib/router/layer.js:95:5)
at next (/home/union/onegram/node_modules/express/lib/router/route.js:131:13)
at Route.dispatch (/home/union/onegram/node_modules/express/lib/router/route.js:112:3)
at Layer.handle [as handle_request] (/home/union/onegram/node_modules/express/lib/router/layer.js:95:5)
at /home/union/onegram/node_modules/express/lib/router/index.js:277:22
at Function.process_params (/home/union/onegram/node_modules/express/lib/router/index.js:330:12)
at next (/home/union/onegram/node_modules/express/lib/router/index.js:271:10)
at Function.handle (/home/union/onegram/node_modules/express/lib/router/index.js:176:3)
at router (/home/union/onegram/node_modules/express/lib/router/index.js:46:12)
at Layer.handle [as handle_request] (/home/union/onegram/node_modules/express/lib/router/layer.js:95:5)
at trim_prefix (/home/union/onegram/node_modules/express/lib/router/index.js:312:13)
at /home/union/onegram/node_modules/express/lib/router/index.js:280:7
at Function.process_params (/home/union/onegram/node_modules/express/lib/router/index.js:330:12)
at next (/home/union/onegram/node_modules/express/lib/router/index.js:271:10)
at /home/union/onegram/node_modules/body-parser/lib/read.js:129:5

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions