Already done - see [lines 70-83](https://github.com/cvan/galaxy-api/pull/50/files#diff-89a86ed33c4ecc385797be79c8c8ac43R70). `usersByEmail` only needs updating when the email address changes, whereas `users` needs updating in either an email or username update, which is why the logic for those two is separated.