fix indent and some variable decl places