Meep3D
Meep3D

Reputation: 3756

Sails has no method 'subscribeToFirehose'

I am trying to create the Firehose functionality as defined in the documentation here. It seems straight-fowards (code follows) but it just keeps giving an error:

TypeError: Object #<Object> has no method 'subscribeToFirehose'

Controller:

module.exports = {

    /**
     * `UserController.index()`
     */
    index: function (req, res) {
        if (!req.isSocket) return res.badRequest();

        sails.sockets.subscribeToFirehose(req.socket);

        // sails.sockets.subscribeToFirehose(req.socket);
        return res.ok();
    }
};

Upvotes: 1

Views: 54

Answers (1)

sgress454
sgress454

Reputation: 24958

Ah, sorry, that should be removed from the docs. If you're using v0.11, the firehose has been deprecated. Read all about it in the migration guide.

Upvotes: 2

Related Questions