fix three errors