Userlist is now saved when applying edits.

As opposed to when the application message loop ends. This fixes #351.
The saving of settings has also been moved to a more appropriate point.