fix apostrophes which can break logging messages