Skip to content

Commit

Permalink
Allow for empty messages
Browse files Browse the repository at this point in the history
  • Loading branch information
dhood committed Mar 29, 2016
1 parent 4f7755b commit fe517f9
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion src/genpy/generator.py
Original file line number Diff line number Diff line change
Expand Up @@ -772,7 +772,7 @@ def msg_generator(msg_context, spec, search_path):

full_text = compute_full_text_escaped(msg_context, spec)
# escape trailing double-quote, unless already escaped, before wrapping in """
if full_text[-1] == '"' and not full_text[-2:] == r'\"':
if full_text.endswith('"') and not full_text.endswith(r'\"'):
full_text = full_text[:-1] + r'\"'
yield ' _full_text = """%s"""'%full_text

Expand Down

0 comments on commit fe517f9

Please sign in to comment.