diff --git a/lib/menubar/menu_gen.lua b/lib/menubar/menu_gen.lua index 7da0e528a..8ff388774 100644 --- a/lib/menubar/menu_gen.lua +++ b/lib/menubar/menu_gen.lua @@ -13,7 +13,6 @@ local utils = require("menubar.utils") local pairs = pairs local ipairs = ipairs local table = table -local gdebug = require("gears.debug") local lgi = require("lgi") local gio = lgi.Gio local protected_call = require("gears.protected_call") @@ -146,8 +145,6 @@ function menu_gen.generate(callback) { name = name, cmdline = cmdline, icon = icon, category = target_category } ) unique_entries[unique_key] = true - else - gdebug.dump(entry, "entry not included") end end end diff --git a/lib/menubar/utils.lua b/lib/menubar/utils.lua index e034ac6ca..4fe4649f1 100644 --- a/lib/menubar/utils.lua +++ b/lib/menubar/utils.lua @@ -382,11 +382,11 @@ function utils.parse_dir(dir_path, callback) end local result = {} - local f = gio.File.new_for_path(dir_path) - parser(f, result) + local dir = gio.File.new_for_path(dir_path) + parser(dir, result) for i, entry in ipairs(result) do - local target = gio.File.new_for_path(entry.file) - local relative_path = f:get_relative_path(target) + local desktop_file = gio.File.new_for_path(entry.file) + local relative_path = dir:get_relative_path(desktop_file) entry.desktop_file_id = string.gsub(relative_path, "/", "-") result[i] = entry end