Miscellaneous improvements
Miscellaneous improvements. Even though they're independent of another, I didn't want to open three separate merge requests for them. If some of this ends up being rejected, I'll happily come up with a new merge request, though.