changeset 1903:0a6764ab0c16

merged main
author Thomas Waldmann <tw AT waldmann-edv DOT de>
date Mon, 19 Mar 2007 22:13:21 +0100
parents 6628902acfe7 (current diff) 86819d96cb01 (diff)
children 82667e81b928
files
diffstat 1 files changed, 6 insertions(+), 1 deletions(-) [+]
line wrap: on
line diff
--- a/MoinMoin/action/SpellCheck.py	Mon Mar 19 22:12:15 2007 +0100
+++ b/MoinMoin/action/SpellCheck.py	Mon Mar 19 22:13:21 2007 +0100
@@ -100,7 +100,6 @@
 
 def _addLocalWords(request):
     from MoinMoin.PageEditor import PageEditor
-
     # get the new words as a string (if any are marked at all)
     try:
         newwords = request.form['newwords']
@@ -209,7 +208,13 @@
 
 def execute(pagename, request):
     _ = request.getText
+
     page = Page(request, pagename)
+    if not request.user.may.write(request.cfg.page_local_spelling_words):
+        msg = _("You can't save spelling words.")
+        page.send_page(msg=msg)
+        return
+
     if request.user.may.read(pagename):
         badwords, badwords_re, msg = checkSpelling(page, request)
     else: