diff options
author | Daniel Silverstone <daniel.silverstone@codethink.co.uk> | 2018-10-24 10:30:20 +0100 |
---|---|---|
committer | Daniel Silverstone <daniel.silverstone@codethink.co.uk> | 2018-10-25 15:43:52 +0100 |
commit | bab617d0c10f29b9c0d1dd3e858d5cf1852b7c08 (patch) | |
tree | 175ec80659ef3c601ffcd2481e61376cf83d4e4b /buildstream | |
parent | 70000b0d45cea222023753cab5d66651fdc78a29 (diff) | |
download | buildstream-bab617d0c10f29b9c0d1dd3e858d5cf1852b7c08.tar.gz |
_platform/linux.py: Simplify return statement
The linter dislikes an if/return/else/return where it can be
simplified to a return of the if condition.
Signed-off-by: Daniel Silverstone <daniel.silverstone@codethink.co.uk>
Diffstat (limited to 'buildstream')
-rw-r--r-- | buildstream/_platform/linux.py | 6 |
1 files changed, 1 insertions, 5 deletions
diff --git a/buildstream/_platform/linux.py b/buildstream/_platform/linux.py index d3be221a7..6e488472f 100644 --- a/buildstream/_platform/linux.py +++ b/buildstream/_platform/linux.py @@ -111,8 +111,4 @@ class Linux(Platform): except subprocess.CalledProcessError: output = '' - if output == 'root': - return True - - else: - return False + return output == 'root' |