@@ -315,16 +315,21 @@ def share(ctx, project):
315315 return
316316 access_list = mc .project_user_permissions (project )
317317
318- for username in access_list .get ("owners" ):
318+ owners = access_list .get ("owners" , [])
319+ writers = access_list .get ("writers" , [])
320+ editors = access_list .get ("editors" , [])
321+ readers = access_list .get ("readers" , [])
322+
323+ for username in owners :
319324 click .echo ("{:20}\t {:20}" .format (username , "owner" ))
320- for username in access_list . get ( " writers" ) :
321- if username not in access_list . get ( " owners" ) :
325+ for username in writers :
326+ if username not in owners :
322327 click .echo ("{:20}\t {:20}" .format (username , "writer" ))
323- for username in access_list . get ( " editors" ) :
324- if username not in access_list . get ( " writers" ) :
328+ for username in editors :
329+ if username not in writers :
325330 click .echo ("{:20}\t {:20}" .format (username , "editor" ))
326- for username in access_list . get ( " readers" ) :
327- if username not in access_list . get ( " editors" ) :
331+ for username in readers :
332+ if username not in editors :
328333 click .echo ("{:20}\t {:20}" .format (username , "reader" ))
329334
330335
0 commit comments