firing action:settings.set hook AFTER the object is saved in the db. What was I thinking?!

v1.18.x
Julian Lam 11 years ago
parent c72d0232f4
commit 84832f57cc

@ -19,8 +19,13 @@ module.exports = function(Meta) {
Meta.settings.set = function(hash, values, callback) {
hash = 'settings:' + hash;
db.setObject(hash, values, function(err) {
if (!err) {
plugins.fireHook('action:settings.set', hash, values);
db.setObject(hash, values, callback);
}
callback.apply(this, arguments);
});
};
Meta.settings.setOne = function(hash, field, value, callback) {

Loading…
Cancel
Save