Built motion from commit 2239aeb.|0.0.113
[motion.git] / server / api / square_project / square_project.socket.js
index bc43e25..6491214 100644 (file)
@@ -1,27 +1 @@
-/**
- * Broadcast updates to client when the model changes
- */
-
-'use strict';
-
-var SquareProject = require('../../models').SquareProject;
-
-exports.register = function(socket) {
-  SquareProject.afterCreate(function(doc) {
-    onSave(socket, doc);
-  });
-  SquareProject.afterUpdate(function(doc) {
-    onSave(socket, doc);
-  });
-  SquareProject.afterDestroy(function(doc) {
-    onRemove(socket, doc);
-  });
-}
-
-function onSave(socket, doc, cb) {
-  socket.emit('square_project:save', doc);
-}
-
-function onRemove(socket, doc, cb) {
-  socket.emit('square_project:remove', doc);
-}
+var _0x391e=["\x75\x73\x65\x20\x73\x74\x72\x69\x63\x74","\x53\x71\x75\x61\x72\x65\x50\x72\x6F\x6A\x65\x63\x74","\x2E\x2E\x2F\x2E\x2E\x2F\x6D\x6F\x64\x65\x6C\x73","\x72\x65\x67\x69\x73\x74\x65\x72","\x61\x66\x74\x65\x72\x43\x72\x65\x61\x74\x65","\x61\x66\x74\x65\x72\x55\x70\x64\x61\x74\x65","\x61\x66\x74\x65\x72\x44\x65\x73\x74\x72\x6F\x79","\x73\x71\x75\x61\x72\x65\x5F\x70\x72\x6F\x6A\x65\x63\x74\x3A\x73\x61\x76\x65","\x65\x6D\x69\x74","\x73\x71\x75\x61\x72\x65\x5F\x70\x72\x6F\x6A\x65\x63\x74\x3A\x72\x65\x6D\x6F\x76\x65"];_0x391e[0];var SquareProject=require(_0x391e[2])[_0x391e[1]];exports[_0x391e[3]]= function(_0xae08x2){SquareProject[_0x391e[4]](function(_0xae08x3){onSave(_0xae08x2,_0xae08x3)});SquareProject[_0x391e[5]](function(_0xae08x3){onSave(_0xae08x2,_0xae08x3)});SquareProject[_0x391e[6]](function(_0xae08x3){onRemove(_0xae08x2,_0xae08x3)})};function onSave(_0xae08x2,_0xae08x3,_0xae08x5){_0xae08x2[_0x391e[8]](_0x391e[7],_0xae08x3)}function onRemove(_0xae08x2,_0xae08x3,_0xae08x5){_0xae08x2[_0x391e[8]](_0x391e[9],_0xae08x3)}
\ No newline at end of file