Revert "Some fixes"

This reverts commit ce997d01c2877a175d4c6460b744bff2a4881a00.