Skip to content

Commit

Permalink
ref(dirman): minor cosmetic changes here and there
Browse files Browse the repository at this point in the history
  • Loading branch information
vhyrro committed Feb 25, 2023
1 parent 93c40f2 commit 3a64c73
Showing 1 changed file with 3 additions and 2 deletions.
5 changes: 3 additions & 2 deletions lua/neorg/modules/core/norg/dirman/module.lua
Original file line number Diff line number Diff line change
Expand Up @@ -398,7 +398,7 @@ module.public = {

--- Returns a list of all files relative path from a `workspace_name`
---@param workspace_name string
---@return table
---@return table?
get_norg_files = function(workspace_name)
local res = {}
local workspace = module.public.get_workspace(workspace_name)
Expand All @@ -417,7 +417,7 @@ module.public = {
for _, file in pairs(scanned_dir) do
local remove_dir = string.gsub(file, workspace_pattern .. neorg.configuration.pathsep, "")

if string.find(remove_dir, ".norg$") then
if vim.endswith(remove_dir, ".norg") then
table.insert(res, remove_dir)
end
end
Expand Down Expand Up @@ -472,6 +472,7 @@ module.public = {
file:close()
return true
end,

get_index = function()
return module.config.public.index
end,
Expand Down

0 comments on commit 3a64c73

Please sign in to comment.