Browse Source

fixed profiles length testing

Gildas 7 năm trước cách đây
mục cha
commit
4f193d0ae1
1 tập tin đã thay đổi với 1 bổ sung1 xóa
  1. 1 1
      extension/ui/bg/ui-menu.js

+ 1 - 1
extension/ui/bg/ui-menu.js

@@ -104,7 +104,7 @@ singlefile.ui.menu = (() => {
 					type: "separator"
 				});
 			}
-			if (config.profiles.length > 1) {
+			if (Object.keys(config.profiles).length > 1) {
 				browser.menus.create({
 					id: MENU_ID_SELECT_PROFILE,
 					title: browser.i18n.getMessage("menuSelectProfile"),