From 3a4467d1fc53c873125662381683a0ff31aa6d5d Mon Sep 17 00:00:00 2001 From: Alexandre Fayolle Date: Mon, 16 Feb 2015 10:34:59 +0100 Subject: [PATCH] fix pep8 W503 Add OCA as author of OCA addons In order to get visibility on https://www.odoo.com/apps the OCA board has decided to add the OCA as author of all the addons maintained as part of the association. --- database_cleanup/__openerp__.py | 2 +- database_cleanup/model/purge_columns.py | 5 +++-- database_cleanup/model/purge_tables.py | 6 +++--- 3 files changed, 7 insertions(+), 6 deletions(-) diff --git a/database_cleanup/__openerp__.py b/database_cleanup/__openerp__.py index ab839f57f..a164e6043 100644 --- a/database_cleanup/__openerp__.py +++ b/database_cleanup/__openerp__.py @@ -22,7 +22,7 @@ { 'name': 'Database cleanup', 'version': '0.1', - 'author': 'Therp BV', + 'author': "Therp BV,Odoo Community Association (OCA)", 'depends': ['base'], 'license': 'AGPL-3', 'category': 'Tools', diff --git a/database_cleanup/model/purge_columns.py b/database_cleanup/model/purge_columns.py index 60b56ccc8..abcf1d2d4 100644 --- a/database_cleanup/model/purge_columns.py +++ b/database_cleanup/model/purge_columns.py @@ -96,8 +96,9 @@ class CleanupPurgeWizardColumn(orm.TransientModel): columns = list(set([ column for model_pool in model_pools for column in model_pool._columns - if not (isinstance(model_pool._columns[column], fields.function) - and not model_pool._columns[column].store) + if not (isinstance(model_pool._columns[column], + fields.function) and + not model_pool._columns[column].store) ])) columns += orm.MAGIC_COLUMNS columns += self.blacklist.get(model_pools[0]._table, []) diff --git a/database_cleanup/model/purge_tables.py b/database_cleanup/model/purge_tables.py index 8d9c86544..50bf3d8e6 100644 --- a/database_cleanup/model/purge_tables.py +++ b/database_cleanup/model/purge_tables.py @@ -110,9 +110,9 @@ class CleanupPurgeWizardTable(orm.TransientModel): known_tables += [ column._sql_names(model_pool)[0] for column in model_pool._columns.values() - if column._type == 'many2many' - # unstored function fields of type m2m don't have _rel - and hasattr(column, '_rel') + if (column._type == 'many2many' and + hasattr(column, '_rel')) # unstored function fields of + # type m2m don't have _rel ] # Cannot pass table names as a psycopg argument