diff --git a/src/route/contents.ts b/src/route/contents.ts index 9609f22..7561f4a 100644 --- a/src/route/contents.ts +++ b/src/route/contents.ts @@ -122,6 +122,9 @@ const ContentHandler = (controller : DocumentAccessor) => async (ctx:Context, ne if (document == undefined){ return sendError(404,"document does not exist."); } + if(document.deleted_at !== null){ + return sendError(404,"document has been removed."); + } const path = join(document.basepath,document.filename); ctx.state['location'] = { path:path,