Skip to content

Commit ea4e79c

Browse files
committed
Fix empty_outbox to actually work as intended when outbox is imported elsewhere
- Legacy-Id: 3702
1 parent 7f8df2e commit ea4e79c

1 file changed

Lines changed: 3 additions & 4 deletions

File tree

ietf/utils/mail.py

Lines changed: 3 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -22,12 +22,11 @@
2222
# ... send some mail ...
2323
# ... inspect ietf.utils.mail.outbox ...
2424
# ... call ietf.utils.mail.empty_outbox() ...
25-
test_mode=False
26-
outbox=[]
25+
test_mode = False
26+
outbox = []
2727

2828
def empty_outbox():
29-
global outbox
30-
outbox = []
29+
outbox[:] = []
3130

3231
def add_headers(msg):
3332
if not(msg.has_key('Message-ID')):

0 commit comments

Comments
 (0)