fix(ci): unused vars

This commit is contained in:
Barrett Ruth 2025-09-21 11:37:08 -04:00
parent 2c994a8bdc
commit c1529c5d91
4 changed files with 18 additions and 5 deletions

View file

@ -82,6 +82,11 @@ local function contest_picker(platform)
problem_picker(platform, contest.id)
end
end,
['ctrl-r'] = function()
local cache = require('cp.cache')
cache.clear_contest_list(platform)
contest_picker(platform)
end,
},
})
end

View file

@ -75,7 +75,7 @@ local function contest_picker(opts, platform)
end,
}),
sorter = conf.generic_sorter(opts),
attach_mappings = function(prompt_bufnr)
attach_mappings = function(prompt_bufnr, map)
actions.select_default:replace(function()
local selection = action_state.get_selected_entry()
actions.close(prompt_bufnr)
@ -84,6 +84,14 @@ local function contest_picker(opts, platform)
problem_picker(opts, platform, selection.value.id)
end
end)
map('i', '<C-r>', function()
local cache = require('cp.cache')
cache.clear_contest_list(platform)
actions.close(prompt_bufnr)
contest_picker(opts, platform)
end)
return true
end,
})