Skip to content

Commit

Permalink
Merge branch 'scop-none-header'
Browse files Browse the repository at this point in the history
  • Loading branch information
jasonrbriggs committed Oct 17, 2015
2 parents 3d30ab4 + ecf83b5 commit 0b090b5
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 1 deletion.
2 changes: 1 addition & 1 deletion stomp/test/utils_test.py
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,7 @@ def test_returns_true_when_localhost(self):
self.assertEquals(2, is_localhost(('192.168.1.92', 8000)))

def test_convert_frame_to_lines(self):
f = Frame('SEND', { 'header1' : 'value1'}, 'this is the body')
f = Frame('SEND', {'header1' : 'value1', 'headerNone': None}, 'this is the body')

lines = convert_frame_to_lines(f)

Expand Down
2 changes: 2 additions & 0 deletions stomp/utils.py
Original file line number Diff line number Diff line change
Expand Up @@ -169,6 +169,8 @@ def convert_frame_to_lines(frame):
lines.append(frame.cmd)
lines.append("\n")
for key, vals in sorted(frame.headers.items()):
if vals is None:
continue
if type(vals) != tuple:
vals = (vals,)
for val in vals:
Expand Down

0 comments on commit 0b090b5

Please sign in to comment.