Move updating user stats into a worker

Closes #11