refactor: Remove testRun and completion check from new stargazers
This commit is contained in:
@@ -43,10 +43,4 @@ export default defineTrigger({
|
||||
async run($) {
|
||||
await newStargazers($);
|
||||
},
|
||||
|
||||
sort(stargazerA, stargazerB) {
|
||||
return (
|
||||
Number(stargazerB.meta.internalId) - Number(stargazerA.meta.internalId)
|
||||
);
|
||||
},
|
||||
});
|
||||
|
@@ -48,9 +48,6 @@ const newStargazers = async ($: IGlobalVariable) => {
|
||||
const { starred_at, user } = starEntry;
|
||||
const timestamp = DateTime.fromISO(starred_at).toMillis();
|
||||
|
||||
if (timestamp <= Number($.flow.lastInternalId) && !$.execution.testRun)
|
||||
return;
|
||||
|
||||
const dataItem = {
|
||||
raw: user,
|
||||
meta: {
|
||||
@@ -61,7 +58,7 @@ const newStargazers = async ($: IGlobalVariable) => {
|
||||
$.pushTriggerItem(dataItem);
|
||||
}
|
||||
}
|
||||
} while (pathname && !$.execution.testRun);
|
||||
} while (pathname);
|
||||
};
|
||||
|
||||
export default newStargazers;
|
||||
|
Reference in New Issue
Block a user