coding style: don't format an empty string with another string

'{}'.format('foo') for any given value of 'foo' (in this case, a
function returning a string), can always just be 'foo' directly, which
is a lot more readable.
pull/9348/head
Eli Schwartz 3 years ago
parent e33ba28ec4
commit cfa8717c4a
No known key found for this signature in database
GPG Key ID: CEB167EFB5722BD6
  1. 2
      mesonbuild/dependencies/detect.py

@ -143,7 +143,7 @@ def find_external_dependency(name: str, env: 'Environment', kwargs: T.Dict[str,
# otherwise, the dependency could not be found
tried_methods = [d.log_tried() for d in pkgdep if d.log_tried()]
if tried_methods:
tried = '{}'.format(mlog.format_list(tried_methods))
tried = mlog.format_list(tried_methods)
else:
tried = ''

Loading…
Cancel
Save