mirror of
https://github.com/kristoferssolo/telescope-frecency.nvim.git
synced 2025-10-21 20:10:38 +00:00
fix: deal with default_workspace option (#114)
This commit is contained in:
parent
0615dd6343
commit
2ffcfd00ed
@ -164,6 +164,7 @@ end
|
||||
---@param tag string?
|
||||
---@return string?
|
||||
function Picker:get_workspace(cwd, tag)
|
||||
tag = tag or self.config.default_workspace_tag
|
||||
if not tag then
|
||||
return nil
|
||||
elseif self.config.workspaces[tag] then
|
||||
@ -236,7 +237,7 @@ function Picker:on_input_filter_cb(picker_opts)
|
||||
if prompt == "" then
|
||||
workspace = self:get_workspace(picker_opts.cwd, self.config.initial_workspace_tag)
|
||||
else
|
||||
workspace = self:get_workspace(picker_opts.cwd, tag or self.config.default_workspace_tag) or self.workspace
|
||||
workspace = self:get_workspace(picker_opts.cwd, tag) or self.workspace
|
||||
end
|
||||
if self.workspace ~= workspace then
|
||||
self.workspace = workspace
|
||||
|
||||
Loading…
Reference in New Issue
Block a user