Multiple small changes and fixes