mirror of
https://github.com/coder/coder.git
synced 2026-09-24 15:04:27 +08:00
feat: use default org for PostUser (#12143)
Instead of assuming only 1 org exists, this uses the is_default org to place a user in if not specified.
This commit is contained in:
@@ -1,3 +1,13 @@
|
||||
-- name: GetDefaultOrganization :one
|
||||
SELECT
|
||||
*
|
||||
FROM
|
||||
organizations
|
||||
WHERE
|
||||
is_default = true
|
||||
LIMIT
|
||||
1;
|
||||
|
||||
-- name: GetOrganizations :many
|
||||
SELECT
|
||||
*
|
||||
|
||||
Reference in New Issue
Block a user