Commit 9b18795c authored by Nicolas Delaby's avatar Nicolas Delaby

guessEncodingFromText is a function not a method of portal_contributions

git-svn-id: https://svn.erp5.org/repos/public/erp5/trunk@41209 20353a03-c40f-0410-a6d1-a30d3c3de9de
parent 34552a4e
...@@ -41,7 +41,7 @@ from Products.ERP5Type.XMLObject import XMLObject ...@@ -41,7 +41,7 @@ from Products.ERP5Type.XMLObject import XMLObject
from Products.ERP5Type.DateUtils import convertDateToHour,\ from Products.ERP5Type.DateUtils import convertDateToHour,\
number_of_hours_in_day, number_of_hours_in_year number_of_hours_in_day, number_of_hours_in_year
from Products.ERP5Type.Utils import convertToUpperCase, fill_args_from_request,\ from Products.ERP5Type.Utils import convertToUpperCase, fill_args_from_request,\
deprecated deprecated, guessEncodingFromText
from Products.ERP5Type.TransactionalVariable import getTransactionalVariable from Products.ERP5Type.TransactionalVariable import getTransactionalVariable
from Products.ERP5Type.Cache import getReadOnlyTransactionCache from Products.ERP5Type.Cache import getReadOnlyTransactionCache
from Products.ERP5.Tool.ContributionTool import MAX_REPEAT from Products.ERP5.Tool.ContributionTool import MAX_REPEAT
...@@ -709,8 +709,7 @@ class Document(DocumentExtensibleTraversableMixin, XMLObject, UrlMixin, ...@@ -709,8 +709,7 @@ class Document(DocumentExtensibleTraversableMixin, XMLObject, UrlMixin,
""" """
Deprecated method Deprecated method
""" """
contribution_tool = self.getPortalObject().portal_contributions return guessEncodingFromText(string, content_type=mime)
return contribution_tool.guessEncodingFromText(string, content_type=mime)
def _stripHTML(self, html, charset=None): def _stripHTML(self, html, charset=None):
""" """
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment