alphagov/govuk_content_models — pull request #12 by alext (2012-08-17 10:52:06+00:00)
Title: Expose tags and tag_ids in json view of Artefact

This will be helpful because in a lot of cases in frontend apps we'll just care whether a tag is set or not. e.g. for the legacy sources, we only care if the directgov or businesslink tag is set.

Exposing the tag_ids as well as the tags will allow us to do:

```ruby
if artefact["tag_ids"].include?('businesslink')
do_stuff
end
```

This change also ensures that an empty array is returned if there are no tags.