Add unit-tests to edit a distro name via the UI
Be consistent in the http error code returned
Be consistent in the order in which we check/return error code