mirror of
https://github.com/zadam/trilium.git
synced 2025-11-12 16:25:51 +01:00
fix(test): tests that got broken along the way
This commit is contained in:
@@ -131,6 +131,7 @@ function renderImageAttachment(image: SNote, res: Response, attachmentName: stri
|
||||
function register(router: Router) {
|
||||
function renderNote(note: SNote, req: Request, res: Response) {
|
||||
if (!note) {
|
||||
console.log("Unable to find note ", note);
|
||||
res.status(404).render("share/404");
|
||||
return;
|
||||
}
|
||||
@@ -215,6 +216,7 @@ function register(router: Router) {
|
||||
|
||||
const { shareId } = req.params;
|
||||
|
||||
console.log("Got share ", shareId, shaca.notes, shaca.aliasToNote);
|
||||
const note = shaca.aliasToNote[shareId] || shaca.notes[shareId];
|
||||
|
||||
renderNote(note, req, res);
|
||||
|
||||
Reference in New Issue
Block a user