aboutsummaryrefslogtreecommitdiffstats
path: root/models/wiki.go
diff options
context:
space:
mode:
Diffstat (limited to 'models/wiki.go')
-rw-r--r--models/wiki.go2
1 files changed, 1 insertions, 1 deletions
diff --git a/models/wiki.go b/models/wiki.go
index 3a39daf0f6..3e0d1b9ce8 100644
--- a/models/wiki.go
+++ b/models/wiki.go
@@ -45,7 +45,7 @@ func WikiNameToFilename(name string) string {
// WikiFilenameToName converts a wiki filename to its corresponding page name.
func WikiFilenameToName(filename string) (string, error) {
if !strings.HasSuffix(filename, ".md") {
- return "", fmt.Errorf("Invalid wiki filename: %s", filename)
+ return "", ErrWikiInvalidFileName{filename}
}
basename := filename[:len(filename)-3]
unescaped, err := url.QueryUnescape(basename)