Fix bootstrap
Fixes #46 and #22