fix 2 problems