Fix for #186 #187