fixed minor formatting and unused var