Skip to content

Commit

Permalink
feat: regularily try to fetch documents from api
Browse files Browse the repository at this point in the history
  • Loading branch information
xeroc committed Dec 1, 2023
1 parent 1b40b5b commit 5cc849c
Showing 1 changed file with 5 additions and 0 deletions.
5 changes: 5 additions & 0 deletions src/main.ts
Original file line number Diff line number Diff line change
Expand Up @@ -63,6 +63,11 @@ export default class RelayMdPLugin extends Plugin {
}
});

// Additionally, we register a timer to fetch documents for us
this.registerInterval(window.setInterval(() => {
this.get_recent_documents();
}, 5 * 60 * 1000)); // 5 minutes

this.addSettingTab(new RelayMDSettingTab(this.app, this));
}

Expand Down

0 comments on commit 5cc849c

Please sign in to comment.