mirror of
https://github.com/yweber/lodel2.git
synced 2025-11-26 07:16:54 +01:00
PEP8 on Reference class
This commit is contained in:
parent
90c3c8518b
commit
2bb71f824f
1 changed files with 2 additions and 1 deletions
|
|
@ -2,6 +2,7 @@
|
|||
from lodel.leapi.datahandlers.field_data_handler import FieldDataHandler
|
||||
from lodel.editorial_model.components import EmClass
|
||||
|
||||
|
||||
class Reference(FieldDataHandler):
|
||||
|
||||
## @brief Instanciation
|
||||
|
|
@ -29,7 +30,7 @@ class Reference(FieldDataHandler):
|
|||
|
||||
if isinstance(value, dict):
|
||||
ref_values = value.values()
|
||||
|
||||
|
||||
for related in value:
|
||||
if not isinstance(related, EmClass):
|
||||
return (value, "The reference %s should be an instance of EmClass, %s gotten" % (related.display_name, related.__class__))
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue