Skip to content

Commit 7789c7b

Browse files
committed
update to new-or-updated-contact
1 parent 30b97f4 commit 7789c7b

File tree

3 files changed

+10
-6
lines changed

3 files changed

+10
-6
lines changed

components/hubspot/package.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
{
22
"name": "@pipedream/hubspot",
3-
"version": "1.2.3",
3+
"version": "1.2.4",
44
"description": "Pipedream Hubspot Components",
55
"main": "hubspot.app.mjs",
66
"keywords": [

components/hubspot/sources/common/common.mjs

Lines changed: 5 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -79,9 +79,11 @@ export default {
7979
}
8080

8181
for (const result of results) {
82-
if (await this.isRelevant(result, after)) {
83-
this.emitEvent(result);
84-
const ts = this.getTs(result);
82+
const ts = this.getTs(result);
83+
if (!after || ts > after) {
84+
if (await this.isRelevant(result, after, ts)) {
85+
this.emitEvent(result);
86+
}
8587
if (ts > maxTs) {
8688
maxTs = ts;
8789
this._setAfter(ts);

components/hubspot/sources/new-or-updated-contact/new-or-updated-contact.mjs

Lines changed: 4 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -9,7 +9,7 @@ export default {
99
key: "hubspot-new-or-updated-contact",
1010
name: "New or Updated Contact",
1111
description: "Emit new event for each new or updated contact in Hubspot.",
12-
version: "0.0.9",
12+
version: "0.0.10",
1313
dedupe: "unique",
1414
type: "source",
1515
props: {
@@ -102,7 +102,9 @@ export default {
102102
limit: DEFAULT_LIMIT,
103103
sorts: [
104104
{
105-
propertyName: "lastmodifieddate",
105+
propertyName: this.newOnly
106+
? "createdate"
107+
: "lastmodifieddate",
106108
direction: "DESCENDING",
107109
},
108110
],

0 commit comments

Comments
 (0)