Fix #45 and add regression test