Clean Up and Bugfix