mirror of
https://github.com/NodeBB/NodeBB.git
synced 2025-11-07 06:25:50 +01:00
fix: improper SSO format (regression), update openapi schema
This commit is contained in:
@@ -512,21 +512,6 @@ UserObjectFull:
|
|||||||
- name
|
- name
|
||||||
- visibility
|
- visibility
|
||||||
- public
|
- public
|
||||||
sso:
|
|
||||||
type: array
|
|
||||||
items:
|
|
||||||
type: object
|
|
||||||
properties:
|
|
||||||
associated:
|
|
||||||
type: boolean
|
|
||||||
url:
|
|
||||||
type: string
|
|
||||||
name:
|
|
||||||
type: string
|
|
||||||
icon:
|
|
||||||
type: string
|
|
||||||
deauthUrl:
|
|
||||||
type: string
|
|
||||||
websiteLink:
|
websiteLink:
|
||||||
type: string
|
type: string
|
||||||
websiteName:
|
websiteName:
|
||||||
|
|||||||
@@ -47,6 +47,21 @@ get:
|
|||||||
type: number
|
type: number
|
||||||
defaultAvatar:
|
defaultAvatar:
|
||||||
type: string
|
type: string
|
||||||
|
sso:
|
||||||
|
type: array
|
||||||
|
items:
|
||||||
|
type: object
|
||||||
|
properties:
|
||||||
|
associated:
|
||||||
|
type: boolean
|
||||||
|
url:
|
||||||
|
type: string
|
||||||
|
name:
|
||||||
|
type: string
|
||||||
|
icon:
|
||||||
|
type: string
|
||||||
|
deauthUrl:
|
||||||
|
type: string
|
||||||
groupSelectSize:
|
groupSelectSize:
|
||||||
type: number
|
type: number
|
||||||
title:
|
title:
|
||||||
|
|||||||
@@ -42,7 +42,8 @@ editController.get = async function (req, res) {
|
|||||||
|
|
||||||
payload.sso = [];
|
payload.sso = [];
|
||||||
if (req.uid === res.locals.uid || canManageUsers) {
|
if (req.uid === res.locals.uid || canManageUsers) {
|
||||||
payload.sso = await plugins.hooks.fire('filter:auth.list', { uid: res.locals.uid, associations: [] });
|
const { associations } = await plugins.hooks.fire('filter:auth.list', { uid: res.locals.uid, associations: [] });
|
||||||
|
payload.sso = associations;
|
||||||
}
|
}
|
||||||
|
|
||||||
if (!allowMultipleBadges) {
|
if (!allowMultipleBadges) {
|
||||||
|
|||||||
Reference in New Issue
Block a user