diff --git a/src/applications/conduit/method/user/base/ConduitAPI_user_Method.php b/src/applications/conduit/method/user/base/ConduitAPI_user_Method.php index 3c32e7ee5f..c2f4ec0e81 100644 --- a/src/applications/conduit/method/user/base/ConduitAPI_user_Method.php +++ b/src/applications/conduit/method/user/base/ConduitAPI_user_Method.php @@ -25,12 +25,24 @@ abstract class ConduitAPI_user_Method extends ConduitAPIMethod { PhabricatorUser $user, PhabricatorUserStatus $current_status = null) { + $roles = array(); + if ($user->getIsDisabled()) { + $roles[] = 'disabled'; + } + if ($user->getIsSystemAgent()) { + $roles[] = 'agent'; + } + if ($user->getIsAdmin()) { + $roles[] = 'admin'; + } + $return = array( 'phid' => $user->getPHID(), 'userName' => $user->getUserName(), 'realName' => $user->getRealName(), 'image' => $user->loadProfileImageURI(), 'uri' => PhabricatorEnv::getURI('/p/'.$user->getUsername().'/'), + 'roles' => $roles, ); if ($current_status) { diff --git a/src/applications/conduit/method/user/info/ConduitAPI_user_info_Method.php b/src/applications/conduit/method/user/info/ConduitAPI_user_info_Method.php index 8f2c444ff4..323183867f 100644 --- a/src/applications/conduit/method/user/info/ConduitAPI_user_info_Method.php +++ b/src/applications/conduit/method/user/info/ConduitAPI_user_info_Method.php @@ -1,7 +1,7 @@