Merge branch 'release/v5.26'
This commit is contained in:
@@ -48,6 +48,13 @@ def processattachment(rower, fileobj, title, uploadoptions,testing=False):
|
||||
except AttributeError:
|
||||
filename = fileobj[6:]
|
||||
|
||||
# test if file exists and is not empty
|
||||
try:
|
||||
with open(filename,'r') as fop:
|
||||
line = fop.readline()
|
||||
except IOError:
|
||||
return 0
|
||||
|
||||
workoutid = [
|
||||
make_new_workout_from_email(rower, filename, title,testing=testing)
|
||||
]
|
||||
@@ -104,7 +111,10 @@ def get_from_address(message):
|
||||
else:
|
||||
body = message.get_body().splitlines()
|
||||
|
||||
first_line = body[0].lower()
|
||||
try:
|
||||
first_line = body[0].lower()
|
||||
except IndexError:
|
||||
first_line = ''
|
||||
|
||||
if "quiske" in first_line:
|
||||
match = re.search(r'[\w\.-]+@[\w\.-]+', first_line)
|
||||
|
||||
Reference in New Issue
Block a user