Fixed some minor issues reported by John