Update search index when legacy-download-stats are set.

As part of the legacy statistics support, update the search index
every time the legacy-download-stats value is changed.
Merge pull request #260 from mhilton/update-es-on-charm-update

Update search index when legacy-download-stats are set.

As part of the legacy statistics support, update the search index
every time the legacy-download-stats value is changed.