Fix code practices