From 89e7995a33f24a1ed0af41e7524b116975246e55 Mon Sep 17 00:00:00 2001 From: Bob Mottram Date: Tue, 26 May 2020 17:08:30 +0100 Subject: [PATCH] More debug --- daemon.py | 18 ++++++++++-------- 1 file changed, 10 insertions(+), 8 deletions(-) diff --git a/daemon.py b/daemon.py index f01bbe116..e19d81f88 100644 --- a/daemon.py +++ b/daemon.py @@ -5420,18 +5420,18 @@ class PubServer(BaseHTTPRequestHandler): for mType in profileMediaTypes: if self.server.debug: print('DEBUG: profile update extracting ' + mType + - ' image from POST') + ' image or font from POST') mediaBytes, postBytes = \ extractMediaInFormPOST(postBytes, boundary, mType) if mediaBytes: if self.server.debug: print('DEBUG: profile update ' + mType + - ' image was found. ' + + ' image or font was found. ' + str(len(mediaBytes)) + ' bytes') else: if self.server.debug: print('DEBUG: profile update, no ' + mType + - ' image was found in POST') + ' image or font was found in POST') continue # Note: a .temp extension is used here so that at no @@ -5455,19 +5455,21 @@ class PubServer(BaseHTTPRequestHandler): filenameBase) if filename: print('Profile update POST ' + mType + - ' media filename is ' + filename) + ' media or font filename is ' + filename) else: print('Profile update, no ' + mType + - ' media filename in POST') + ' media or font filename in POST') continue - if self.server.debug: - print('DEBUG: POST ' + mType + - ' media removing metadata') postImageFilename = filename.replace('.temp', '') if mType == 'customFont': copyfile(filename, postImageFilename) + print('profile POST ' + mType + + ' image or font filename ' + postImageFilename) else: + if self.server.debug: + print('DEBUG: POST ' + mType + + ' media removing metadata') removeMetaData(filename, postImageFilename) if os.path.isfile(postImageFilename): print('profile update POST ' + mType +