From 40a8a3f8fee7baadd181fe82e356d56abc412351 Mon Sep 17 00:00:00 2001 From: Dylan Baker Date: Mon, 15 Nov 2021 13:19:39 -0800 Subject: modules/gnome: fix warning message that will always fire `typed_pos_args` ensures that the length of args is always true. --- mesonbuild/modules/gnome.py | 5 ++--- 1 file changed, 2 insertions(+), 3 deletions(-) diff --git a/mesonbuild/modules/gnome.py b/mesonbuild/modules/gnome.py index 70d8c9c..962bbb1 100644 --- a/mesonbuild/modules/gnome.py +++ b/mesonbuild/modules/gnome.py @@ -1051,9 +1051,8 @@ class GnomeModule(ExtensionModule): sources = args[1] if not sources: raise MesonException('Yelp requires a list of sources') - else: - if len(args) > 1: - mlog.warning('"gnome.yelp" ignores positional sources arguments when the "sources" keyword argument is set') + elif args[1]: + mlog.warning('"gnome.yelp" ignores positional sources arguments when the "sources" keyword argument is set') source_str = '@@'.join(sources) langs = kwargs['languages'] -- cgit v1.1