Skip to content

Commit

Permalink
Merge pull request #1350 from myk002/myk_repeat_util_api
Browse files Browse the repository at this point in the history
use the new repeat-util API for querying
  • Loading branch information
myk002 authored Dec 25, 2024
2 parents 0a5380c + ecabf51 commit cb8fc90
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 4 deletions.
4 changes: 2 additions & 2 deletions internal/control-panel/common.lua
Original file line number Diff line number Diff line change
Expand Up @@ -73,7 +73,7 @@ function get_enabled_map()
end
end
-- repeat entries override tool names for control-panel
for munged_name in pairs(repeatUtil.repeating) do
for _,munged_name in ipairs(repeatUtil.listScheduled()) do
local name = unmunge_repeat_name(munged_name)
if name then
enabled_map[name] = true
Expand Down Expand Up @@ -118,7 +118,7 @@ local function persist_repeats()
local cp_repeats = {}
for _, data in ipairs(registry.COMMANDS_BY_IDX) do
if data.mode == 'repeat' then
if repeatUtil.repeating[munge_repeat_name(data.command)] then
if repeatUtil.isScheduled(munge_repeat_name(data.command)) then
cp_repeats[data.command] = true
else
cp_repeats[data.command] = false
Expand Down
4 changes: 2 additions & 2 deletions repeat.lua
Original file line number Diff line number Diff line change
Expand Up @@ -46,8 +46,8 @@ elseif args.command then
end

if args.list then
for k in pairs(repeatUtil.repeating) do
print(k)
for _,name in ipairs(repeatUtil.listScheduled()) do
print(name)
end
return
end

0 comments on commit cb8fc90

Please sign in to comment.