Very few minor bug fixes