table collapse bugfix; fixes #22