Fix issues 191 and 192