File tree 1 file changed +4
-0
lines changed
src/recensio/plone/browser
1 file changed +4
-0
lines changed Original file line number Diff line number Diff line change 4
4
from itertools import chain
5
5
from plone import api
6
6
from plone .app .textfield .value import RichTextValue
7
+ from plone .protect .interfaces import IDisableCSRFProtection
7
8
from Products .CMFCore .utils import getToolByName
8
9
from Products .Five .browser import BrowserView
9
10
from recensio .plone .sehepunkte import sehepunkte_parser
10
11
from recensio .plone .tools import convertToString
11
12
from z3c .relationfield .relation import RelationValue
12
13
from zope .component import getUtility
13
14
from zope .event import notify
15
+ from zope .interface import alsoProvides
14
16
from zope .intid .interfaces import IIntIds
15
17
from zope .lifecycleevent import ObjectModifiedEvent
16
18
from zope .schema .interfaces import IVocabularyFactory
@@ -126,6 +128,8 @@ def __call__(self):
126
128
total ,
127
129
total and review_count / total or review_count ,
128
130
)
131
+ if review_count > 0 :
132
+ alsoProvides (self .request , IDisableCSRFProtection )
129
133
return "Success"
130
134
131
135
def _getTargetURLs (self ):
You can’t perform that action at this time.
0 commit comments