Several fixes
Updated version