From a0adefc740f261a7dc6ae2ff5994b171658c7ec6 Mon Sep 17 00:00:00 2001 From: Bobby Date: Thu, 5 May 2022 13:23:18 +0700 Subject: [PATCH] fix: album public page failing when no description --- routes/album.js | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/routes/album.js b/routes/album.js index 85b03c9..4493890 100644 --- a/routes/album.js +++ b/routes/album.js @@ -76,7 +76,9 @@ routes.get('/a/:identifier', async (req, res, next) => { : `api/album/zip/${album.identifier}?v=${album.editedAt}` album.url = `a/${album.identifier}` - album.description = utils.md.instance.render(album.description) + album.description = album.description + ? utils.md.instance.render(album.description) + : null return res.render('album', { config,