diff --git a/lua/cp/pickers/fzf_lua.lua b/lua/cp/pickers/fzf_lua.lua index fee8217..2e5095c 100644 --- a/lua/cp/pickers/fzf_lua.lua +++ b/lua/cp/pickers/fzf_lua.lua @@ -1,6 +1,8 @@ local picker_utils = require('cp.pickers') -local function contest_picker(platform) +local contest_picker, problem_picker + +function contest_picker(platform) local constants = require('cp.constants') local platform_display_name = constants.PLATFORM_DISPLAY_NAMES[platform] or platform local fzf = require('fzf-lua') @@ -51,7 +53,7 @@ local function contest_picker(platform) }) end -local function problem_picker(platform, contest_id) +function problem_picker(platform, contest_id) local constants = require('cp.constants') local platform_display_name = constants.PLATFORM_DISPLAY_NAMES[platform] or platform local fzf = require('fzf-lua') diff --git a/lua/cp/pickers/telescope.lua b/lua/cp/pickers/telescope.lua index 5dc3e51..4c3188e 100644 --- a/lua/cp/pickers/telescope.lua +++ b/lua/cp/pickers/telescope.lua @@ -6,7 +6,9 @@ local actions = require('telescope.actions') local picker_utils = require('cp.pickers') -local function contest_picker(opts, platform) +local contest_picker, problem_picker + +function contest_picker(opts, platform) local constants = require('cp.constants') local platform_display_name = constants.PLATFORM_DISPLAY_NAMES[platform] or platform local contests = picker_utils.get_contests_for_platform(platform) @@ -57,7 +59,7 @@ local function contest_picker(opts, platform) :find() end -local function problem_picker(opts, platform, contest_id) +function problem_picker(opts, platform, contest_id) local constants = require('cp.constants') local platform_display_name = constants.PLATFORM_DISPLAY_NAMES[platform] or platform local problems = picker_utils.get_problems_for_contest(platform, contest_id)