fix todotxt autosort
This commit is contained in:
parent
8d0b4bef5e
commit
5a30250932
13
main.js
13
main.js
|
@ -2283,7 +2283,12 @@ function searchandloadnote()
|
|||
|
||||
function currentistodo()
|
||||
{
|
||||
return title.value.includes("todo") || gettags(md.value).includes("todo");
|
||||
return istodo(title.value, md.value);
|
||||
}
|
||||
|
||||
function istodo(title, content)
|
||||
{
|
||||
return title.includes("todo") || gettags(content).includes("todo");
|
||||
}
|
||||
|
||||
function sorttodotxt(content)
|
||||
|
@ -2862,10 +2867,10 @@ function loadnote(title)
|
|||
}
|
||||
}
|
||||
|
||||
/*if (settings.autosorttodo && istodo(note))
|
||||
if (settings.autosorttodo && istodo(title, content))
|
||||
{
|
||||
sorttodotxt(note);
|
||||
}*/
|
||||
content = sorttodotxt(content);
|
||||
}
|
||||
|
||||
bind(item.title, content, item.pos);
|
||||
|
||||
|
|
Loading…
Reference in New Issue