Fix issue 191 and 192