From 42426f816bafae5d863f16dcb05135dfa773e387 Mon Sep 17 00:00:00 2001 From: Campbell Barton Date: Tue, 4 Sep 2012 20:31:19 +0000 Subject: code cleanup: python - pass multiple args to string startswith() / endswith() functions rather than calling multiple times. --- io_import_gimp_image_to_scene.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'io_import_gimp_image_to_scene.py') diff --git a/io_import_gimp_image_to_scene.py b/io_import_gimp_image_to_scene.py index 4605fe1d..bc09c75f 100644 --- a/io_import_gimp_image_to_scene.py +++ b/io_import_gimp_image_to_scene.py @@ -85,7 +85,7 @@ def main(File, Path, LayerViewers, MixerViewers, LayerOffset, for Segment in Line.split(): if Segment.startswith('w/h:'): ResX, ResY = map (int, Segment[4:].split(',')) - if Line.startswith("b'L") or Line.startswith("b'l"): + if Line.startswith(("b'L", "b'l")): """The "nice" method to check if layer has alpha channel sadly GIMP sometimes decides not to export an alpha channel -- cgit v1.2.3