summaryrefslogtreecommitdiff
path: root/packages/backend/src/server/file (follow)
Commit message (Collapse)AuthorAgeFilesLines
* なんかもうめっちゃ変えたsyuilo2022-09-188-166/+0
|
* refactor: temporary files (#8713)Johann1502022-05-251-7/+2
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | * simplify temporary files for thumbnails Because only a single file will be written to the directory, creating a separate directory seems unnecessary. If only a temporary file is created, the code from `createTemp` can be reused here as well. * refactor: deduplicate code for temporary files/directories To follow the DRY principle, the same code should not be duplicated across different files. Instead an already existing function is used. Because temporary directories are also create in multiple locations, a function for this is also newly added to reduce duplication. * fix: clean up identicon temp files The temporary files for identicons are not reused and can be deleted after they are fully read. This condition is met when the stream is closed and so the file can be cleaned up using the events API of the stream. * fix: ensure cleanup is called when download fails * fix: ensure cleanup is called in error conditions This covers import/export queue jobs and is mostly just wrapping all code in a try...finally statement where the finally runs the cleanup. * fix: use correct type instead of `any`
* enhance: ↵tamaina2022-04-281-5/+3
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | ドライブに画像ファイルをアップロードするときオリジナル画像を破棄してwebpublicのみ保持するオプション (#8216) * wip * Update packages/client/src/os.ts Co-authored-by: tamaina <tamaina@hotmail.co.jp> * メニューをComposition API化、switchアイテム追加 クライアントサイド画像圧縮の準備 * メニュー型定義を分離 (TypeScriptの型支援が効かないので) * disabled * make keepOriginal to follow setting value * :v: * fix * fix * :v: * WEBP * aaa * :v: * webp * lazy load browser-image-resizer * rename * rename 2 * Fix * clean up * add comment * clean up * jpeg, pngにもどす * fix * fix name * webpでなくする ただしサムネやプレビューはwebpのまま (テスト) * 動画サムネイルはjpegに * エラーハンドリング * :v: * v2.2.1-misskey-beta.2 * browser-image-resizer#v2.2.1-misskey.1 * :v: * fix alert * update browser-image-resizer to v2.2.1-misskey.2 * lockfile Co-authored-by: mei23 <m@m544.net> Co-authored-by: MeiMei <30769358+mei23@users.noreply.github.com>
* fix(server): dummy image is not served correctlysyuilo2022-03-121-1/+1
| | | | Fix #8393
* refactor: Use ESM (#8358)syuilo2022-02-272-27/+25
| | | | | | | | | | | | | | | * wip * wip * fix * clean up * Update tsconfig.json * Update activitypub.ts * wip
* Add `img-src` and `media-src` to `Content-Security-Policy` header for files ↵shibao2022-01-291-1/+1
| | | | | | | | | and media proxy (#8188) * add img-src and media-src to csp in file and media proxy * add csp changes to changelog * sort and remove trailing semicolon
* send-drive-file svg as png (#8107)tamaina2022-01-201-2/+8
|
* Revert "revert d53795184"syuilo2022-01-011-3/+5
| | | | This reverts commit aedbab17cc400ae7ac17498463504f40646e8673.
* revert d53795184syuilo2021-12-291-5/+3
|
* refactorsyuilo2021-12-261-4/+4
|
* enhance(server): better content type detectionsyuilo2021-12-261-3/+5
|
* fix lintsyuilo2021-12-091-1/+1
|
* refactoringsyuilo2021-11-128-0/+167
Resolve #7779