diff --git a/slackpost.py b/slackpost.py index d487d1f..a054c95 100755 --- a/slackpost.py +++ b/slackpost.py @@ -52,7 +52,7 @@ thread_id = match.group(0).rsplit("=")[-1].rstrip() # - Quoted text will always begin with ">" # - The email reply will always have "Reply sent on " text # -message = re.sub(">(.*?)\n", "", payload).rstrip() +message = re.sub("^>(.*?)\n", "", payload, flags=re.MULTILINE).rstrip() split = message.split("\n") message = "\n".join(split[:-1]).rstrip()