From e216ebc62db7a23788a7a48e88fca3963f4711f3 Mon Sep 17 00:00:00 2001 From: Ulf Magnusson Date: Fri, 7 Dec 2012 03:13:46 +0100 Subject: Small simplification. --- kconfiglib.py | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) (limited to 'kconfiglib.py') diff --git a/kconfiglib.py b/kconfiglib.py index 4d6c994..041deca 100644 --- a/kconfiglib.py +++ b/kconfiglib.py @@ -3232,13 +3232,12 @@ class Choice(Item, _HasVisibility): """Returns the mode of the choice. See the class documentation for an explanation of modes.""" minimum_mode = "n" if self.optional else "m" - mode = self.user_mode if self.user_mode is not None else minimum_mode mode = self.config._eval_min(mode, self._calc_visibility()) # Promote "m" to "y" for boolean choices if mode == "m" and self.type == BOOL: - mode = "y" + return "y" return mode -- cgit v1.2.3