Skip to content

Commit

Permalink
chore(cli): remove python2 code
Browse files Browse the repository at this point in the history
  • Loading branch information
nejch committed Oct 12, 2020
1 parent 9054a3b commit 1030e0a
Showing 1 changed file with 1 addition and 5 deletions.
6 changes: 1 addition & 5 deletions gitlab/v4/cli.py
Expand Up @@ -85,11 +85,7 @@ def do_project_export_download(self):
try:
project = self.gl.projects.get(int(self.args["project_id"]), lazy=True)
data = project.exports.get().download()
if hasattr(sys.stdout, "buffer"):
# python3
sys.stdout.buffer.write(data)
else:
sys.stdout.write(data)
sys.stdout.buffer.write(data)

except Exception as e:
cli.die("Impossible to download the export", e)
Expand Down

0 comments on commit 1030e0a

Please sign in to comment.