Big bugfix and prepare for release