Multiple fixes and implementation of new features