Fix for github issue #4