From f934c2917f2244380b1ab7402fed06db51468691 Mon Sep 17 00:00:00 2001 From: mappu Date: Sun, 29 Oct 2017 15:09:53 +1300 Subject: [PATCH] catch one more case of title normalisation --- DB.go | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/DB.go b/DB.go index 702d3fe..fab87fc 100644 --- a/DB.go +++ b/DB.go @@ -92,7 +92,7 @@ func (this *WikiDB) GetRevision(revId int) (*Article, error) { } func (this *WikiDB) GetLatestVersion(title string) (*Article, error) { - row := this.db.QueryRow(`SELECT articles.* FROM articles WHERE article = (SELECT id FROM titles WHERE title = ?) ORDER BY modified DESC LIMIT 1`, title) + row := this.db.QueryRow(`SELECT articles.* FROM articles WHERE article = (SELECT id FROM titles WHERE title = ?) ORDER BY modified DESC LIMIT 1`, this.normaliseTitle(title)) return this.parseArticle(row) }