StudiesController#update: don't cast nil to 0

This fixes a bug etienne reported.