Skip site navigation (1)Skip section navigation (2)
Date:      Wed, 21 Feb 2018 04:23:13 +0000 (UTC)
From:      Kyle Evans <kevans@FreeBSD.org>
To:        src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org
Subject:   svn commit: r329698 - head/stand/lua
Message-ID:  <201802210423.w1L4NDZY095921@repo.freebsd.org>

next in thread | raw e-mail | index | archive | help
Author: kevans
Date: Wed Feb 21 04:23:13 2018
New Revision: 329698
URL: https://svnweb.freebsd.org/changeset/base/329698

Log:
  lualoader: Directly reference submenu definition with submenu key

Modified:
  head/stand/lua/menu.lua

Modified: head/stand/lua/menu.lua
==============================================================================
--- head/stand/lua/menu.lua	Wed Feb 21 04:14:32 2018	(r329697)
+++ head/stand/lua/menu.lua	Wed Feb 21 04:23:13 2018	(r329698)
@@ -75,7 +75,7 @@ menu.handlers = {
 	end,
 	[core.MENU_SUBMENU] = function(current_menu, entry)
 		-- recurse
-		return menu.run(entry.submenu())
+		return menu.run(entry.submenu)
 	end,
 	[core.MENU_RETURN] = function(current_menu, entry)
 		-- allow entry to have a function/side effect
@@ -313,9 +313,7 @@ menu.welcome = {
 				return "Boot " .. color.highlight("O") ..
 				    "ptions"
 			end,
-			submenu = function()
-				return menu.boot_options
-			end,
+			submenu = menu.boot_options,
 			alias = {"o", "O"}
 		},
 	},



Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?201802210423.w1L4NDZY095921>