Some essential fixes & improvements