a
This commit is contained in:
parent
9e1d276bbd
commit
9c905f84e8
7 changed files with 80 additions and 45 deletions
|
|
@ -458,6 +458,9 @@ export const meta = {
|
|||
DiscordWebhookUrl: {
|
||||
type: 'string',
|
||||
optional: false, nullable: true,
|
||||
}, DiscordWebhookUrlWordBlock: {
|
||||
type: 'string',
|
||||
optional: false, nullable: true,
|
||||
},
|
||||
enableProxyCheckio: {
|
||||
type: 'boolean',
|
||||
|
|
@ -595,6 +598,7 @@ export default class extends Endpoint<typeof meta, typeof paramDef> { // eslint-
|
|||
perUserListTimelineCacheMax: instance.perUserListTimelineCacheMax,
|
||||
notesPerOneAd: instance.notesPerOneAd,
|
||||
DiscordWebhookUrl: instance.DiscordWebhookUrl,
|
||||
DiscordWebhookUrlWordBlock: instance.DiscordWebhookUrlWordBlock,
|
||||
EmojiBotToken: instance.EmojiBotToken,
|
||||
ApiBase: instance.ApiBase,
|
||||
enableGDPRMode: instance.enableGDPRMode,
|
||||
|
|
|
|||
|
|
@ -92,6 +92,7 @@ export const paramDef = {
|
|||
},
|
||||
summalyProxy: { type: 'string', nullable: true },
|
||||
DiscordWebhookUrl: { type: 'string', nullable: true },
|
||||
DiscordWebhookUrlWordBlock: { type: 'string', nullable: true },
|
||||
deeplAuthKey: { type: 'string', nullable: true },
|
||||
deeplIsPro: { type: 'boolean' },
|
||||
enableEmail: { type: 'boolean' },
|
||||
|
|
@ -210,6 +211,9 @@ export default class extends Endpoint<typeof meta, typeof paramDef> { // eslint-
|
|||
if (ps.DiscordWebhookUrl !== undefined) {
|
||||
set.DiscordWebhookUrl = ps.DiscordWebhookUrl;
|
||||
}
|
||||
if (ps.DiscordWebhookUrlWordBlock !== undefined) {
|
||||
set.DiscordWebhookUrlWordBlock = ps.DiscordWebhookUrlWordBlock;
|
||||
}
|
||||
if (ps.EmojiBotToken !== undefined) {
|
||||
set.EmojiBotToken = ps.EmojiBotToken;
|
||||
}
|
||||
|
|
|
|||
|
|
@ -61,7 +61,6 @@ const clientAssets = `${_dirname}/../../../../frontend/assets/`;
|
|||
const assets = `${_dirname}/../../../../../built/_frontend_dist_/`;
|
||||
const swAssets = `${_dirname}/../../../../../built/_sw_dist_/`;
|
||||
const viteOut = `${_dirname}/../../../../../built/_vite_/`;
|
||||
const tarball = `${_dirname}/../../../../../built/tarball/`;
|
||||
|
||||
@Injectable()
|
||||
export class ClientServerService {
|
||||
|
|
@ -309,18 +308,6 @@ export class ClientServerService {
|
|||
decorateReply: false,
|
||||
});
|
||||
|
||||
fastify.register((fastify, options, done) => {
|
||||
fastify.register(fastifyStatic, {
|
||||
root: tarball,
|
||||
prefix: '/tarball/',
|
||||
maxAge: ms('30 days'),
|
||||
immutable: true,
|
||||
decorateReply: false,
|
||||
});
|
||||
fastify.addHook('onRequest', handleRequestRedirectToOmitSearch);
|
||||
done();
|
||||
});
|
||||
|
||||
fastify.get('/favicon.ico', async (request, reply) => {
|
||||
return reply.sendFile('/favicon.ico', staticAssets);
|
||||
});
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue