mirror of
https://github.com/galaxyproject/galaxy.git
synced 2026-10-25 00:12:08 +08:00
add case where no user is logged in
This commit is contained in:
@@ -1,2 +1,6 @@
|
||||
def main(trans, webhook):
|
||||
return {'username': trans.user.username}
|
||||
if trans.user:
|
||||
user = trans.user.username
|
||||
else:
|
||||
user = 'No user is logged in.'
|
||||
return {'username': user}
|
||||
|
||||
Reference in New Issue
Block a user