Possible fix to #200

Unconfirmed as of yet, but appears to work.