From e27c6c804baf9abdf10268c410c4a831d5d7fa0f Mon Sep 17 00:00:00 2001 From: Stefan Monnier Date: Fri, 30 Aug 2002 21:35:53 +0000 Subject: [PATCH] (custom-group-menu-create): Only cdr if possible since custom-menu-create might return a single menu entry (a vector). --- lisp/cus-edit.el | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/lisp/cus-edit.el b/lisp/cus-edit.el index 7f48db888ba..ce9829578f4 100644 --- a/lisp/cus-edit.el +++ b/lisp/cus-edit.el @@ -3694,7 +3694,8 @@ or (if there were none) at the end of the buffer." "Ignoring WIDGET, create a menu entry for customization group SYMBOL." `( ,(custom-unlispify-menu-entry symbol t) :filter (lambda (&rest junk) - (cdr (custom-menu-create ',symbol))))) + (let ((menu (custom-menu-create ',symbol))) + (if (consp menu) (cdr menu) menu))))) ;;;###autoload (defun custom-menu-create (symbol) -- 2.39.2