Skip to content

Build your personal knowledge base with Trilium Notes

fix: match custom path strictly

soulsandsc3c6d73bb2be
diff --git a/src/routes/custom.js b/src/routes/custom.js
index 077c730cdb..f32f7445fc 100644
--- a/src/routes/custom.js
+++ b/src/routes/custom.js
@@ -19,7 +19,7 @@ function handleRequest(req, res) {
continue;
}
- const regex = new RegExp(attr.value);
+ const regex = new RegExp(`^${attr.value}$`);
let match;
try {