Commit ddbdb7f8 authored by Jérome Perrin's avatar Jérome Perrin

ingestion: fix pylint messages and enable coding style test

parent 1e876ac5
# This script uses file= argument
# pylint: disable=redefined-builtin
""" """
Use to contribute file to ERP5. Use to contribute file to ERP5.
""" """
......
...@@ -88,7 +88,7 @@ elif group_reference_path: ...@@ -88,7 +88,7 @@ elif group_reference_path:
if category is None: if category is None:
break break
if category is not None: if category is not None:
new_dict['group'] = '/'.join(category.getRelativeUrl().split('/')[1:]) new_dict['group'] = '/'.join(category.getRelativeUrl().split('/')[1:])
else: else:
......
autorized_format_list = [] autorized_format_item_list = []
format_list = context.getTargetFormatItemList() for format_item_list in context.getTargetFormatItemList():
for format in format_list: if context.Document_isTargetFormatPermitted(format_item_list[1]):
if context.Document_isTargetFormatPermitted(format[1]): autorized_format_item_list.append(format_item_list)
autorized_format_list.append(format) return autorized_format_item_list
return autorized_format_list
# This script uses file= argument
# pylint: disable=redefined-builtin
""" """
This script provides a facility to permit conversion by format. This script provides a facility to permit conversion by format.
""" """
...@@ -25,7 +27,7 @@ if format in ('html', 'stripped-html', 'text', 'txt', 'pdf', 'png', 'jpg', 'gif' ...@@ -25,7 +27,7 @@ if format in ('html', 'stripped-html', 'text', 'txt', 'pdf', 'png', 'jpg', 'gif'
if format.endswith('pdf'): if format.endswith('pdf'):
return True return True
if format.endswith('html'): if format.endswith('html'):
return True return True
## ##
## # All other formats are prohibitted ## # All other formats are prohibitted
return False return False
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