@inflector/optima-pg 1.1.0 → 1.1.1

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.
Files changed (2) hide show
  1. package/dist/index.js +4 -1
  2. package/package.json +1 -1
package/dist/index.js CHANGED
@@ -640,7 +640,10 @@ var Table = class {
640
640
  // ── Realtime ────────────────────────────────────────────────────────────────
641
641
  Subscribe(callback) {
642
642
  return this.listenFn(this.name, (payload) => {
643
- callback(JSON.parse(payload));
643
+ const event = JSON.parse(payload);
644
+ if (event.new) event.new = this.deserializeRow(event.new);
645
+ if (event.old) event.old = this.deserializeRow(event.old);
646
+ callback(event);
644
647
  });
645
648
  }
646
649
  };
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@inflector/optima-pg",
3
- "version": "1.1.0",
3
+ "version": "1.1.1",
4
4
  "type": "module",
5
5
  "author": "Inflector",
6
6
  "main": "./dist/index.js",