Bug fixes

#22