News for hackers. Stuff that matters.
Re:Announcing Backbone.js 1.0 by philfreo on Wednesday March 20, 2013 @11:51AM (#5407990)

    // Override Backbone.sync to use the PUT HTTP method for PATCH requests
    // when doing Model#save({...}, { patch: true });
    var originalSync = Backbone.sync;
    Backbone.sync = function(method, model, options) {
        if (method === 'patch') options.type = 'PUT';
        return originalSync(method, model, options);
    };

There are no comments on this comment yet.