Issue 196

Fixes #196.

Like #197, but merging into v1.3.0 instead of master.