mirror of
https://git.joinsharkey.org/Sharkey/Sharkey.git
synced 2024-11-10 11:43:09 +02:00
oops
This commit is contained in:
parent
1311db8060
commit
d69b919961
1 changed files with 3 additions and 3 deletions
|
@ -27,16 +27,16 @@ export default async function(ctx: Koa.Context) {
|
||||||
|
|
||||||
if (file == null) {
|
if (file == null) {
|
||||||
ctx.status = 404;
|
ctx.status = 404;
|
||||||
await send(ctx, `${__dirname}/assets/dummy.png`, { root: assets });
|
await send(ctx, '/dummy.png', { root: assets });
|
||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
|
|
||||||
if (file.metadata.deletedAt) {
|
if (file.metadata.deletedAt) {
|
||||||
ctx.status = 410;
|
ctx.status = 410;
|
||||||
if (file.metadata.isExpired) {
|
if (file.metadata.isExpired) {
|
||||||
await send(ctx, `${__dirname}/assets/cache-expired.png`, { root: assets });
|
await send(ctx, '/cache-expired.png', { root: assets });
|
||||||
} else {
|
} else {
|
||||||
await send(ctx, `${__dirname}/assets/tombstone.png`, { root: assets });
|
await send(ctx, '/tombstone.png', { root: assets });
|
||||||
}
|
}
|
||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
|
|
Loading…
Reference in a new issue