mirror of
https://git.joinsharkey.org/Sharkey/Sharkey.git
synced 2024-11-10 05:13:09 +02:00
upd: masto api support more types
This commit is contained in:
parent
487e397810
commit
0758e38237
1 changed files with 8 additions and 0 deletions
|
@ -1,5 +1,6 @@
|
|||
import { Inject, Injectable } from '@nestjs/common';
|
||||
import megalodon, { Entity, MegalodonInterface } from 'megalodon';
|
||||
import multipart from '@fastify/multipart';
|
||||
import { IsNull } from 'typeorm';
|
||||
import multer from 'fastify-multer';
|
||||
import type { UsersRepository } from '@/models/_.js';
|
||||
|
@ -42,6 +43,13 @@ export class MastodonApiServerService {
|
|||
|
||||
fastify.register(multer.contentParser);
|
||||
|
||||
fastify.register(multipart, {
|
||||
limits: {
|
||||
fileSize: this.config.maxFileSize ?? 262144000,
|
||||
files: 1,
|
||||
},
|
||||
});
|
||||
|
||||
fastify.get('/v1/custom_emojis', async (_request, reply) => {
|
||||
const BASE_URL = `${_request.protocol}://${_request.hostname}`;
|
||||
const accessTokens = _request.headers.authorization;
|
||||
|
|
Loading…
Reference in a new issue