Skip to content
Merged
Show file tree
Hide file tree
Changes from 1 commit
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Prev Previous commit
Next Next commit
linting and formatting
  • Loading branch information
Emyrk committed Aug 22, 2024
commit cb6281313a1f3809ff453a87b56b266b321b43af
5 changes: 2 additions & 3 deletions coderd/users.go
Original file line number Diff line number Diff line change
Expand Up @@ -388,8 +388,8 @@ func (api *API) postUser(rw http.ResponseWriter, r *http.Request) {

if len(req.OrganizationIDs) == 0 {
httpapi.Write(ctx, rw, http.StatusBadRequest, codersdk.Response{
Message: fmt.Sprintf("No organization specified to place the user as a member of. It is required to specify at least one organization id to place the user in."),
Detail: fmt.Sprintf("required at least 1 value for the array 'organization_ids'"),
Message: "No organization specified to place the user as a member of. It is required to specify at least one organization id to place the user in.",
Detail: "required at least 1 value for the array 'organization_ids'",
Validations: []codersdk.ValidationError{
{
Field: "organization_ids",
Expand Down Expand Up @@ -447,7 +447,6 @@ func (api *API) postUser(rw http.ResponseWriter, r *http.Request) {
})
return
}

}

var loginType database.LoginType
Expand Down
2 changes: 1 addition & 1 deletion site/e2e/api.ts
Original file line number Diff line number Diff line change
Expand Up @@ -37,7 +37,7 @@ export const createUser = async (orgId: string) => {
password: "s3cure&password!",
login_type: "password",
disable_login: false,
organization_id: orgId,
organization_ids: [orgId],
});
return user;
};
Expand Down