@live-change/framework 0.5.20 → 0.5.24

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/index.js CHANGED
@@ -12,6 +12,7 @@ module.exports.app = () => {
12
12
  module.exports.utils = require('./lib/utils.js')
13
13
  module.exports.validation = require('./lib/utils/validation.js')
14
14
  module.exports.rangeProperties = module.exports.utils.rangeProperties
15
+ module.exports.encodeIdentifier = module.exports.utils.encodeIdentifier
15
16
 
16
17
 
17
18
  module.exports.ActionDefinition = require('./lib/definition/ActionDefinition.js')
package/lib/App.js CHANGED
@@ -98,7 +98,15 @@ class App {
98
98
  processors.unshift(...service.processors)
99
99
  }
100
100
  processUse(sourceService)
101
- for(let processor of processors) processor(sourceService, this)
101
+ //console.log("FOUND PROCESSORS", processors.length)
102
+ processors = processors.filter(function(item, pos, self) {
103
+ return self.indexOf(item) == pos
104
+ })
105
+ //console.log("RUNNING PROCESSORS", processors.length)
106
+ for(let processor of processors) {
107
+ //console.log("PROCESSOR", processor)
108
+ processor(sourceService, this)
109
+ }
102
110
  }
103
111
 
104
112
  computeChanges( oldServiceJson, newService ) {
package/lib/utils.js CHANGED
@@ -246,8 +246,16 @@ function fieldListToFieldsObject(fieldList) {
246
246
  return fields
247
247
  }
248
248
 
249
+ function encodeIdentifier(parts) {
250
+ if(!Array.isArray(parts)) {
251
+ return parts
252
+ }
253
+ return parts.map(p => JSON.stringify(p)).join(':')
254
+ }
255
+
249
256
  module.exports = {
250
257
  typeName, toJSON, setDifference, mapDifference, crudChanges,
251
258
  getProperty, setProperty, getField, setField, isObject, mergeDeep, generateDefault,
252
- prefixRange, rangeProperties, fieldListToFieldsObject
259
+ prefixRange, rangeProperties, fieldListToFieldsObject,
260
+ encodeIdentifier
253
261
  }
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@live-change/framework",
3
- "version": "0.5.20",
3
+ "version": "0.5.24",
4
4
  "description": "Live Change Framework - ultimate solution for real time mobile/web apps",
5
5
  "main": "index.js",
6
6
  "scripts": {
@@ -21,13 +21,13 @@
21
21
  },
22
22
  "homepage": "https://github.com/live-change/live-change-framework",
23
23
  "devDependencies": {
24
- "@live-change/dao": "^0.3.13",
25
- "@live-change/dao-websocket": "^0.3.2",
26
- "@live-change/db": "^0.3.64",
27
- "@live-change/db-store-level": "^0.1.15",
28
- "@live-change/db-store-lmdb": "^0.1.22",
24
+ "@live-change/dao": "0.4.2",
25
+ "@live-change/dao-websocket": "0.4.1",
26
+ "@live-change/db": "0.5.4",
27
+ "@live-change/db-store-level": "0.5.4",
28
+ "@live-change/db-store-lmdb": "0.5.4",
29
29
  "@live-change/sockjs": "^0.4.0-rc.1",
30
- "@live-change/uid": "^0.5.20",
30
+ "@live-change/uid": "0.5.20",
31
31
  "cookie": "^0.4.1",
32
32
  "express": "^4.17.1",
33
33
  "os-service": "^2.2.0",
@@ -35,5 +35,5 @@
35
35
  "tape": "^5.3.2",
36
36
  "websocket": "^1.0.34"
37
37
  },
38
- "gitHead": "d37be156c4f76af3ead4ad0aae3f80281191bf57"
38
+ "gitHead": "2fb6050c59e88d0dd285d640e454819d30130b0b"
39
39
  }