wiki: Ensure to normalize page name on create check.

This commit is contained in:
Andre D
2012-12-12 01:18:45 -05:00
committed by Neil Williams
parent d332dc4410
commit 0a03256226

View File

@@ -310,6 +310,9 @@ class VWikiPageRevise(VWikiPage):
# Should not happen, but just in case
self.set_error('EMPTY_PAGE_NAME', 403)
return
page = normalize_page(page)
if c.is_wiki_mod and WikiPage.is_special(page):
return {'reason': 'PAGE_CREATED_ELSEWHERE'}
elif (not c.user_is_admin) and WikiPage.is_restricted(page):