Skip to content

How to custom response 408 timeout on spesific route? #799

@aalfiann

Description

@aalfiann

Hi sir,

I used this to handle the response timeout in totaljs 3,

ROUTE('#408', function () {
    var self = this;
    self.json({ code: 408, message: 'Error timeout!'});
});

That will return same timeout response for all routes and that's OK.

Right now, I want to custom the response timeout only to spesific route, but the other routes still using default timeout response like above?

Is this possible? How to do this in TotalJS 3?

Thanks for your help.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions