Skip to content

Request for support check for authorize #135

@VitaliyR

Description

@VitaliyR

Hello!

I've found that

oauth.authorise()

is checking for authentication in strict mode - thats means that if user is not authenticated - he receives error JSON with 'no token'.

I am suggesting to create another middleware method (or extend this one) to support non strict check - it would do exact same as autorise but if token wrong/non existing just continue pipe execution in usual way.

server.get('/items/:id', server.oauth.authorise(false /*non-strict, default true*/), this.controllers['itemsController'].show);

What do you think?

P.S. I've managed to make a lot of changes with my backend because we are using restify and it have differences with express. Maybe... add support for it too? :)

Metadata

Metadata

Assignees

No one assigned

    Labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions