Skip to content

Commit 7db93f3

Browse files
committed
fix(init): increment the default timeout to 15 seconds
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.
1 parent 8515266 commit 7db93f3

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

lua/orgmode/init.lua

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -50,7 +50,7 @@ function Org:init()
5050
:new({
5151
paths = require('orgmode.config').org_agenda_files,
5252
})
53-
:load_sync()
53+
:load_sync(nil, 15000)
5454
self.agenda = require('orgmode.agenda'):new({
5555
files = self.files,
5656
})

0 commit comments

Comments
 (0)