You've already forked obsidian-visualiser
Sync now includes tags
This commit is contained in:
@@ -20,16 +20,13 @@ export default defineCachedEventHandler(async (e) => {
|
||||
const where = ["project = $project", "tag = $tag"];
|
||||
const criteria: Record<string, any> = { $project: project, $tag: tag };
|
||||
|
||||
if(where.length > 1)
|
||||
const db = useDatabase();
|
||||
|
||||
const content = db.query(`SELECT * FROM explorer_tags WHERE ${where.join(" and ")}`).get(criteria) as Tag;
|
||||
|
||||
if(content !== undefined)
|
||||
{
|
||||
const db = useDatabase();
|
||||
|
||||
const content = db.query(`SELECT * FROM explorer_tags WHERE ${where.join(" and ")}`).get(criteria) as Tag;
|
||||
|
||||
if(content !== undefined)
|
||||
{
|
||||
return content;
|
||||
}
|
||||
return content;
|
||||
}
|
||||
|
||||
setResponseStatus(e, 404);
|
||||
|
||||
Reference in New Issue
Block a user