Skip to content
Snippets Groups Projects
Commit fba36561 authored by syuilo's avatar syuilo
Browse files

Merge branch 'master' of https://github.com/syuilo/misskey

parents c32385b6 39d87305
No related branches found
No related tags found
No related merge requests found
......@@ -56,11 +56,12 @@ function thumbnail(data: stream.Readable, type: string, resize: number): ISend {
const readable: stream.Readable = (() => {
// 動画であれば
if (/^video\/.*$/.test(type)) {
// 実装は先延ばし
// TODO
// 使わないことになったストリームはしっかり取り壊す
data.destroy();
return fs.createReadStream(`${__dirname}/assets/thumbnail-not-available.png`);
// 画像であれば
// Note: SVGはapplication/xml
} else if (/^image\/.*$/.test(type) || type == 'application/xml') {
// 0フレーム目を送る
try {
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment