From: Scott Worley Date: Thu, 27 Jan 2022 19:40:09 +0000 (-0800) Subject: Sort log apply actions X-Git-Url: http://git.scottworley.com/vopamoi/commitdiff_plain/6a5644f3a4e8f13ab79cc4ac44ea29f0d5f1fad3?ds=inline Sort log apply actions --- diff --git a/vopamoi.ts b/vopamoi.ts index c079bd4..6cee2a1 100644 --- a/vopamoi.ts +++ b/vopamoi.ts @@ -115,14 +115,14 @@ function Log(prefix: string = "vp-") { const [createTimestamp, description] = splitN(data, " ", 1); return Model.edit(createTimestamp, description); } - if (command == "State") { - const [createTimestamp, state] = splitN(data, " ", 1); - return Model.setState(timestamp, createTimestamp, state); - } if (command == "Priority") { const [createTimestamp, newPriority] = splitN(data, " ", 1); return Model.setPriority(createTimestamp, parseFloat(newPriority)); } + if (command == "State") { + const [createTimestamp, state] = splitN(data, " ", 1); + return Model.setState(timestamp, createTimestamp, state); + } }, record: function (entry: string) {