diff options
| author | Acid Chicken (硫酸鶏) <root@acid-chicken.com> | 2024-02-17 13:34:50 +0900 |
|---|---|---|
| committer | GitHub <noreply@github.com> | 2024-02-17 13:34:50 +0900 |
| commit | acba96c1d34572ed7bd454462c2462d2a32369f4 (patch) | |
| tree | 9960987a3d6b39847bcf252514eca58650f9d59c /packages/backend/src/server/api/endpoints/admin | |
| parent | feat: add link to local note in initial comment of abuse note (#13347) (diff) | |
| download | sharkey-acba96c1d34572ed7bd454462c2462d2a32369f4.tar.gz sharkey-acba96c1d34572ed7bd454462c2462d2a32369f4.tar.bz2 sharkey-acba96c1d34572ed7bd454462c2462d2a32369f4.zip | |
feat: license violation protection (#13285)
* spec(frontend): aboutページにリポジトリ・フィードバックのURLを表示させる
Cherry-picked from MisskeyIO#441
Cherry-picked from MisskeyIO#438
* feat: license violation protection
* build: fix typo
* build: fix typo
* fix: farewell to the static type land
* fix: key typo
* fix: import typo
* fix: properly interpret `prominently`
* docs: add disclaimer
* docs: update CHANGELOG
* chore: add gap
---------
Co-authored-by: まっちゃとーにゅ <17376330+u1-liquid@users.noreply.github.com>
Co-authored-by: syuilo <4439005+syuilo@users.noreply.github.com>
Diffstat (limited to 'packages/backend/src/server/api/endpoints/admin')
| -rw-r--r-- | packages/backend/src/server/api/endpoints/admin/meta.ts | 2 | ||||
| -rw-r--r-- | packages/backend/src/server/api/endpoints/admin/update-meta.ts | 6 |
2 files changed, 4 insertions, 4 deletions
diff --git a/packages/backend/src/server/api/endpoints/admin/meta.ts b/packages/backend/src/server/api/endpoints/admin/meta.ts index ef569722e0..88c5907bcc 100644 --- a/packages/backend/src/server/api/endpoints/admin/meta.ts +++ b/packages/backend/src/server/api/endpoints/admin/meta.ts @@ -429,7 +429,7 @@ export const meta = { }, repositoryUrl: { type: 'string', - optional: false, nullable: false, + optional: false, nullable: true, }, summalyProxy: { type: 'string', diff --git a/packages/backend/src/server/api/endpoints/admin/update-meta.ts b/packages/backend/src/server/api/endpoints/admin/update-meta.ts index 51075ed3c6..bffceef815 100644 --- a/packages/backend/src/server/api/endpoints/admin/update-meta.ts +++ b/packages/backend/src/server/api/endpoints/admin/update-meta.ts @@ -104,8 +104,8 @@ export const paramDef = { swPublicKey: { type: 'string', nullable: true }, swPrivateKey: { type: 'string', nullable: true }, tosUrl: { type: 'string', nullable: true }, - repositoryUrl: { type: 'string' }, - feedbackUrl: { type: 'string' }, + repositoryUrl: { type: 'string', nullable: true }, + feedbackUrl: { type: 'string', nullable: true }, impressumUrl: { type: 'string', nullable: true }, privacyPolicyUrl: { type: 'string', nullable: true }, useObjectStorage: { type: 'boolean' }, @@ -402,7 +402,7 @@ export default class extends Endpoint<typeof meta, typeof paramDef> { // eslint- } if (ps.repositoryUrl !== undefined) { - set.repositoryUrl = ps.repositoryUrl; + set.repositoryUrl = URL.canParse(ps.repositoryUrl!) ? ps.repositoryUrl : null; } if (ps.feedbackUrl !== undefined) { |