diff options
author | Michael D Kinney <michael.d.kinney@intel.com> | 2023-11-10 11:30:50 -0800 |
---|---|---|
committer | mergify[bot] <37929162+mergify[bot]@users.noreply.github.com> | 2023-11-11 02:31:13 +0000 |
commit | 1cb580be85d01b6bd76449dc9615b044da9a23b1 (patch) | |
tree | 48f424b4ddde3fb9c2b80aa29504b67ae724a52f | |
parent | 431ead235f37781e68c3661ed300546b00be0611 (diff) | |
download | edk2-1cb580be85d01b6bd76449dc9615b044da9a23b1.tar.gz edk2-1cb580be85d01b6bd76449dc9615b044da9a23b1.tar.bz2 edk2-1cb580be85d01b6bd76449dc9615b044da9a23b1.zip |
BaseTools/Scripts/GetMaintainer: Simplify logic
REF: https://bugzilla.tianocore.org/show_bug.cgi?id=4593
get_section_maintainers() either returns a list with
valid entries or an empty list. It never returns None.
Simplify logic that accumulates maintainers and lists by
unconditionally appending lists returned from
get_section_maintainers().
Cc: Rebecca Cran <rebecca@bsdio.com>
Cc: Liming Gao <gaoliming@byosoft.com.cn>
Cc: Bob Feng <bob.c.feng@intel.com>
Cc: Yuwei Chen <yuwei.chen@intel.com>
Cc: Leif Lindholm <quic_llindhol@quicinc.com>
Signed-off-by: Michael D Kinney <michael.d.kinney@intel.com>
Acked-by: Rebecca Cran <rebecca@bsdio.com>
Reviewed-by: Leif Lindholm <quic_llindhol@quicinc.com>
-rw-r--r-- | BaseTools/Scripts/GetMaintainer.py | 6 |
1 files changed, 2 insertions, 4 deletions
diff --git a/BaseTools/Scripts/GetMaintainer.py b/BaseTools/Scripts/GetMaintainer.py index 2a3147c059..cdcdff7506 100644 --- a/BaseTools/Scripts/GetMaintainer.py +++ b/BaseTools/Scripts/GetMaintainer.py @@ -105,10 +105,8 @@ def get_maintainers(path, sections, level=0): lists = []
for section in sections:
tmp_maint, tmp_lists = get_section_maintainers(path, section)
- if tmp_maint:
- maintainers += tmp_maint
- if tmp_lists:
- lists += tmp_lists
+ maintainers += tmp_maint
+ lists += tmp_lists
if not maintainers:
# If no match found, look for match for (nonexistent) file
|