mirror of
https://github.com/ansible/awx.git
synced 2026-01-18 21:21:21 -03:30
only discard if groups have been created previously
This commit is contained in:
parent
850934c89d
commit
ee09d881a4
@ -5,9 +5,10 @@ from channels.sessions import channel_session
|
||||
|
||||
|
||||
def discard_groups(message):
|
||||
for group in message.channel_session['groups']:
|
||||
print("removing from group: {}".format(group))
|
||||
Group(group).discard(message.reply_channel)
|
||||
if 'groups' in message.channel_session:
|
||||
for group in message.channel_session['groups']:
|
||||
print("removing from group: {}".format(group))
|
||||
Group(group).discard(message.reply_channel)
|
||||
|
||||
@channel_session
|
||||
def ws_disconnect(message):
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user