if block["reason"] == None or block["reason"] == '':
message = message + block["blocked"] + " with unspecified reason\n"
else:
- message = message + block["blocked"] + ' for "' + block["reason"] + '"\n'
+ if len(block["reason"]) > 420:
+ block["reason"] = block["reason"][0:419] + "[…]"
+ message = message + block["blocked"] + ' for "' + block["reason"].replace("@", "@\u200b") + '"\n'
if truncated:
message = message + "(the list has been truncated to the first 20 entries)"