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