[fix] Fix migration for 1.4.0 which does not add CodeKeyword entity type cubicweb-keyword-version-1.6.0
authorPierre-Yves David <pierre-yves.david@logilab.fr>
Wed, 10 Feb 2010 08:20:56 +0100
changeset 101 b9c77c4c40b8
parent 100 51a5ff34b984
child 102 294a50fe9772
[fix] Fix migration for 1.4.0 which does not add CodeKeyword entity type
migration/1.4.0_Any.py
--- a/migration/1.4.0_Any.py	Wed Feb 10 08:15:26 2010 +0100
+++ b/migration/1.4.0_Any.py	Wed Feb 10 08:20:56 2010 +0100
@@ -1,4 +1,5 @@
-for entity in ('Keyword', 'CodeKeyword'):
-    add_relation_definition(entity, 'descendant_of', entity)
-    sync_schema_props_perms(entity)
+add_entity_type('CodeKeyword')
+
+add_relation_definition('Keyword', 'descendant_of', 'Keyword')
+sync_schema_props_perms('Keyword')
 checkpoint()