Added nice messages for transition.
Added security.

I put in a secret key to ensure that anyone can’t just make the app
perform the processing-intensive task of updating.  I also changed the
error message.
Added view averages/totals.