@flatfile/listener 0.1.1 → 0.1.2

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.
@@ -1,5 +1,5 @@
1
1
 
2
- > @flatfile/listener@0.1.1 build
2
+ > @flatfile/listener@0.1.2 build
3
3
  > tsup src/index.ts --format esm,cjs --dts
4
4
 
5
5
  CLI Building entry: src/index.ts
@@ -8,10 +8,10 @@
8
8
  CLI Target: es2020
9
9
  ESM Build start
10
10
  CJS Build start
11
- ESM dist/index.mjs 25.91 KB
12
- ESM ⚡️ Build success in 180ms
13
11
  CJS dist/index.js 26.77 KB
14
- CJS ⚡️ Build success in 188ms
12
+ CJS ⚡️ Build success in 164ms
13
+ ESM dist/index.mjs 25.91 KB
14
+ ESM ⚡️ Build success in 179ms
15
15
  DTS Build start
16
- DTS ⚡️ Build success in 7000ms
16
+ DTS ⚡️ Build success in 5925ms
17
17
  DTS dist/index.d.ts 7.48 KB
package/CHANGELOG.md CHANGED
@@ -1,5 +1,11 @@
1
1
  # @flatfile/listener
2
2
 
3
+ ## 0.1.2
4
+
5
+ ### Patch Changes
6
+
7
+ - 22d2466: Pull last 5 seconds of events in Polling Driver
8
+
3
9
  ## 0.1.1
4
10
 
5
11
  ### Patch Changes
package/dist/index.js CHANGED
@@ -814,7 +814,7 @@ var PollingEventDriver = class extends EventDriver {
814
814
  accessToken: this.accessToken,
815
815
  apiUrl: this.apiUrl
816
816
  });
817
- let lastTimestamp = /* @__PURE__ */ new Date();
817
+ let lastTimestamp = new Date(Date.now() - 5e3);
818
818
  if (!this.environmentId) {
819
819
  throw new Error("environmentId is required");
820
820
  }
@@ -846,7 +846,7 @@ var PollingEventDriver = class extends EventDriver {
846
846
  }
847
847
  });
848
848
  }).catch(console.error);
849
- lastTimestamp = /* @__PURE__ */ new Date();
849
+ lastTimestamp = new Date(Date.now() - 5e3);
850
850
  }, 500);
851
851
  }
852
852
  shutdown() {
package/dist/index.mjs CHANGED
@@ -794,7 +794,7 @@ var PollingEventDriver = class extends EventDriver {
794
794
  accessToken: this.accessToken,
795
795
  apiUrl: this.apiUrl
796
796
  });
797
- let lastTimestamp = /* @__PURE__ */ new Date();
797
+ let lastTimestamp = new Date(Date.now() - 5e3);
798
798
  if (!this.environmentId) {
799
799
  throw new Error("environmentId is required");
800
800
  }
@@ -826,7 +826,7 @@ var PollingEventDriver = class extends EventDriver {
826
826
  }
827
827
  });
828
828
  }).catch(console.error);
829
- lastTimestamp = /* @__PURE__ */ new Date();
829
+ lastTimestamp = new Date(Date.now() - 5e3);
830
830
  }, 500);
831
831
  }
832
832
  shutdown() {
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@flatfile/listener",
3
- "version": "0.1.1",
3
+ "version": "0.1.2",
4
4
  "description": "A PubSub Listener for configuring and using Flatfile",
5
5
  "main": "dist/index.js",
6
6
  "module": "dist/index.mjs",
@@ -37,7 +37,7 @@ export class PollingEventDriver extends EventDriver {
37
37
  apiUrl: this.apiUrl,
38
38
  })
39
39
 
40
- let lastTimestamp = new Date()
40
+ let lastTimestamp = new Date(Date.now() - 5000)
41
41
  if (!this.environmentId) {
42
42
  throw new Error('environmentId is required')
43
43
  }
@@ -74,7 +74,7 @@ export class PollingEventDriver extends EventDriver {
74
74
  })
75
75
  .catch(console.error)
76
76
 
77
- lastTimestamp = new Date()
77
+ lastTimestamp = new Date(Date.now() - 5000)
78
78
  }, 500)
79
79
  }
80
80