map-transform 0.4.0-alpha.26 → 0.4.0-alpha.27

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.
@@ -2,12 +2,12 @@
2
2
  Object.defineProperty(exports, "__esModule", { value: true });
3
3
  const definitionHelpers_1 = require("../utils/definitionHelpers");
4
4
  const extractPipeline = (pipelineId, { pipelines }) => pipelineId && pipelines ? pipelines[pipelineId] : undefined;
5
+ const removeFlip = ({ flip, ...state }) => state;
5
6
  function apply(pipelineId) {
6
7
  return (options) => (next) => {
7
8
  const pipeline = extractPipeline(pipelineId, options);
8
- return pipeline
9
- ? (0, definitionHelpers_1.operationFromDef)(pipeline)(options)(next)
10
- : (state) => next(state);
9
+ const fn = pipeline ? (0, definitionHelpers_1.operationFromDef)(pipeline)(options)(next) : next;
10
+ return (state) => fn(removeFlip(state));
11
11
  };
12
12
  }
13
13
  exports.default = apply;
@@ -1 +1 @@
1
- {"version":3,"file":"apply.js","sourceRoot":"","sources":["../../src/operations/apply.ts"],"names":[],"mappings":";;AACA,kEAA6D;AAE7D,MAAM,eAAe,GAAG,CAAC,UAAkB,EAAE,EAAE,SAAS,EAAW,EAAE,EAAE,CACrE,UAAU,IAAI,SAAS,CAAC,CAAC,CAAC,SAAS,CAAC,UAAU,CAAC,CAAC,CAAC,CAAC,SAAS,CAAA;AAE7D,SAAwB,KAAK,CAAC,UAAkB;IAC9C,OAAO,CAAC,OAAO,EAAE,EAAE,CAAC,CAAC,IAAI,EAAE,EAAE;QAC3B,MAAM,QAAQ,GAAG,eAAe,CAAC,UAAU,EAAE,OAAO,CAAC,CAAA;QACrD,OAAO,QAAQ;YACb,CAAC,CAAC,IAAA,oCAAgB,EAAC,QAAQ,CAAC,CAAC,OAAO,CAAC,CAAC,IAAI,CAAC;YAC3C,CAAC,CAAC,CAAC,KAAK,EAAE,EAAE,CAAC,IAAI,CAAC,KAAK,CAAC,CAAA;IAC5B,CAAC,CAAA;AACH,CAAC;AAPD,wBAOC"}
1
+ {"version":3,"file":"apply.js","sourceRoot":"","sources":["../../src/operations/apply.ts"],"names":[],"mappings":";;AACA,kEAA6D;AAE7D,MAAM,eAAe,GAAG,CAAC,UAAkB,EAAE,EAAE,SAAS,EAAW,EAAE,EAAE,CACrE,UAAU,IAAI,SAAS,CAAC,CAAC,CAAC,SAAS,CAAC,UAAU,CAAC,CAAC,CAAC,CAAC,SAAS,CAAA;AAE7D,MAAM,UAAU,GAAG,CAAC,EAAE,IAAI,EAAE,GAAG,KAAK,EAAS,EAAE,EAAE,CAAC,KAAK,CAAA;AAEvD,SAAwB,KAAK,CAAC,UAAkB;IAC9C,OAAO,CAAC,OAAO,EAAE,EAAE,CAAC,CAAC,IAAI,EAAE,EAAE;QAC3B,MAAM,QAAQ,GAAG,eAAe,CAAC,UAAU,EAAE,OAAO,CAAC,CAAA;QACrD,MAAM,EAAE,GAAG,QAAQ,CAAC,CAAC,CAAC,IAAA,oCAAgB,EAAC,QAAQ,CAAC,CAAC,OAAO,CAAC,CAAC,IAAI,CAAC,CAAC,CAAC,CAAC,IAAI,CAAA;QACtE,OAAO,CAAC,KAAK,EAAE,EAAE,CAAC,EAAE,CAAC,UAAU,CAAC,KAAK,CAAC,CAAC,CAAA;IACzC,CAAC,CAAA;AACH,CAAC;AAND,wBAMC"}
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "map-transform",
3
- "version": "0.4.0-alpha.26",
3
+ "version": "0.4.0-alpha.27",
4
4
  "description": "Map and transform objects with mapping definitions",
5
5
  "author": "Kjell-Morten Bratsberg Thorsen <post@kjellmorten.no>",
6
6
  "license": "ISC",