File tree Expand file tree Collapse file tree 1 file changed +16
-0
lines changed Expand file tree Collapse file tree 1 file changed +16
-0
lines changed Original file line number Diff line number Diff line change @@ -428,11 +428,27 @@ function OrgMappings:_todo_change_state(direction)
428428 section_config = nil
429429 end
430430
431+ -- @type nil | false | 'time' | 'note'
432+ local user_config
433+ if config .org_todo_keywords ~= nil then
434+ local todoConfig = TodoConfig :parse (table.concat (config .org_todo_keywords , ' ' ))
435+ if todoConfig ~= nil then
436+ user_config = todoConfig :get_logging_behavior (old_state , new_state )
437+ else
438+ -- TODO: Report invalid config?
439+ user_config = nil
440+ end
441+ else
442+ user_config = nil
443+ end
444+
431445 -- Use the most locally available log config
432446 --- @type false | ' time' | ' note'
433447 local log_config
434448 if section_config ~= nil then
435449 log_config = section_config
450+ elseif user_config ~= nil then
451+ log_config = user_config
436452 else
437453 log_config = global_config
438454 end
You can’t perform that action at this time.
0 commit comments