FIXES #1833, thanks @stefanpenner