ndunand/moodle-mod_choicegroup — pull request #53 by guifort (2014-09-09 13:17:00+00:00)
Title: Bugfix the user's choice cache.

After removing a choice, the method `choicegroup_get_user_answer` returns some outdated data because of its cache. This cause the form to not be fully updated before a manual refresh, e.g., the label *Your selection: xxx* is still displayed and the link *Remove my choice* is still visible instead of the button *Save my choice*.

The new `$refresh` parameter solve this problem by reseting the cache.

Example:

**Before I pressed the link *"Remove my choice"***
![screen shot 2014-09-09 at 3 10 13 pm](https://cloud.githubusercontent.com/assets/6701530/4201854/cf0875a4-3822-11e4-9a16-ece29cd4ad6d.png)

**After I pressed the link *"Remove my choice"* (without the bug fix)**
![screen shot 2014-09-09 at 3 10 27 pm](https://cloud.githubusercontent.com/assets/6701530/4201855/d6cc413a-3822-11e4-8c9f-4e69fdd0c32f.png)

**After I pressed the link *"Remove my choice"* (with the bug fix)**
![screen shot 2014-09-09 at 3 10 40 pm](https://cloud.githubusercontent.com/assets/6701530/4201856/de10713c-3822-11e4-805b-f3c1f8930f87.png)