BUGFIX: mutliple tiny bugs