this should fix #40
Merge 80dbeab63d28005e2d4d88f5124e12e4ff0798f9 into dec51e033e39cfbaa713036e21e7af149d176231