Small fixes of new code