1
# Copyright 2013 Canonical Ltd. This software is licensed under the
2
# GNU Affero General Public License version 3 (see the file LICENSE).
4
from charmworld.qa_questions import iter_categories
7
def upgrade(db, index_client):
8
"""Update each category of questions from new_category_data.
10
This update elaborates on the 001_* migration. Subsequent qa form
11
migrations can replace new_category_data and run this same method.
14
for category_dict in iter_categories():
15
db.qa.insert(category_dict)