From 431a3b9ab4053791c45929f2a2bcf921aafed6a1 Mon Sep 17 00:00:00 2001 From: John Glover Date: Tue, 7 Feb 2012 13:19:27 +0000 Subject: [PATCH] [1720][logic/converters] Update for change in location of Vocabulary get function --- ckan/logic/converters.py | 6 ++---- 1 file changed, 2 insertions(+), 4 deletions(-) diff --git a/ckan/logic/converters.py b/ckan/logic/converters.py index 80fb6379bbd..112179b4752 100644 --- a/ckan/logic/converters.py +++ b/ckan/logic/converters.py @@ -44,23 +44,21 @@ def callable(key, data, errors, context): if k[0] == 'tags': n = max(n, k[1] + 1) - # validate for tag in new_tags: tag_length_validator(tag, context) tag_name_validator(tag, context) - v = vocabulary.get(vocab) + v = model.Vocabulary.get(vocab) if not v: raise Invalid(_('Tag vocabulary "%s" does not exist') % vocab) for num, tag in enumerate(new_tags): data[('tags', num+n, 'name')] = tag data[('tags', num+n, 'vocabulary_id')] = v.id - return callable def convert_from_tags(vocab): def callable(key, data, errors, context): - v = vocabulary.get(vocab) + v = model.Vocabulary.get(vocab) if not v: raise Invalid(_('Tag vocabulary "%s" does not exist') % vocab)