Skip to content

Commit

Permalink
fix(init): increment the default timeout to 15 seconds
Browse files Browse the repository at this point in the history
On slow devices (for example Android smartphones using Termux), loading
a lot of org files takes more than 5 seconds, which will make the
default timeout for the promise to expire, leaving the plugin in a
semi-loaded state where some functionalities may not work, forcing the
user to reload the plugin multiple times hoping that the system has
something already cached and it will take less than 5 seconds.
  • Loading branch information
massix committed Jul 24, 2024
1 parent 8515266 commit 7db93f3
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion lua/orgmode/init.lua
Original file line number Diff line number Diff line change
Expand Up @@ -50,7 +50,7 @@ function Org:init()
:new({
paths = require('orgmode.config').org_agenda_files,
})
:load_sync()
:load_sync(nil, 15000)
self.agenda = require('orgmode.agenda'):new({
files = self.files,
})
Expand Down

0 comments on commit 7db93f3

Please sign in to comment.