From ba8496ae366f8f949495fbbc5cb116fd0014fb1b Mon Sep 17 00:00:00 2001 From: Goffi Date: Tue, 25 Aug 2020 08:52:46 +0200 Subject: [PATCH] plugin XEP-0264: only log "fix orientation" when the option is used --- sat/memory/memory.py | 3 +-- sat/plugins/plugin_xep_0264.py | 6 +++--- 2 files changed, 4 insertions(+), 5 deletions(-) diff --git a/sat/memory/memory.py b/sat/memory/memory.py index 726cffae..9e3ca3bd 100644 --- a/sat/memory/memory.py +++ b/sat/memory/memory.py @@ -1,7 +1,6 @@ #!/usr/bin/env python3 - -# SAT: a jabber client +# SàT: an XMPP client # Copyright (C) 2009-2020 Jérôme Poisson (goffi@goffi.org) # This program is free software: you can redistribute it and/or modify diff --git a/sat/plugins/plugin_xep_0264.py b/sat/plugins/plugin_xep_0264.py index 119ec763..d087e20b 100644 --- a/sat/plugins/plugin_xep_0264.py +++ b/sat/plugins/plugin_xep_0264.py @@ -1,7 +1,6 @@ #!/usr/bin/env python3 - -# SAT plugin for managing xep-0264 +# SàT plugin for managing xep-0264 # Copyright (C) 2009-2020 Jérôme Poisson (goffi@goffi.org) # Copyright (C) 2014 Emmanuel Gil Peyrot (linkmauve@linkmauve.fr) @@ -163,7 +162,8 @@ class XEP_0264(object): PLUGIN_INFO[C.PI_IMPORT_NAME], uid, MIME_TYPE, max_age ) as f: img.save(f, SAVE_FORMAT) - log.debug(f"fixed orientation for {f.name}") + if fix_orientation: + log.debug(f"fixed orientation for {f.name}") return img.size, uid