Skip to content

Commit 594fcec

Browse files
remove deploy hook
1 parent f71cb60 commit 594fcec

File tree

1 file changed

+0
-26
lines changed

1 file changed

+0
-26
lines changed

components/notion/sources/updated-page/updated-page.mjs

Lines changed: 0 additions & 26 deletions
Original file line numberDiff line numberDiff line change
@@ -40,32 +40,6 @@ export default {
4040
},
4141
},
4242
hooks: {
43-
async deploy() {
44-
const propertiesToCheck = await this._getPropertiesToCheck();
45-
const propertyValues = {};
46-
const params = this.lastUpdatedSortParam();
47-
const pagesStream = this.notion.getPages(this.databaseId, params);
48-
let count = 0;
49-
let lastUpdatedTimestamp = 0;
50-
for await (const page of pagesStream) {
51-
for (const propertyName of propertiesToCheck) {
52-
const currentValue = this._maybeRemoveFileSubItems(page.properties[propertyName]);
53-
propertyValues[page.id] = {
54-
...propertyValues[page.id],
55-
[propertyName]: currentValue,
56-
};
57-
}
58-
lastUpdatedTimestamp = Math.max(
59-
lastUpdatedTimestamp,
60-
Date.parse(page.last_edited_time),
61-
);
62-
if (count++ < 25) {
63-
this._emitEvent(page);
64-
}
65-
}
66-
this._setPropertyValues(propertyValues);
67-
this.setLastUpdatedTimestamp(lastUpdatedTimestamp);
68-
},
6943
async activate() {
7044
console.log("Restarting -- fetching all pages and properties");
7145
const now = new Date();

0 commit comments

Comments
 (0)