remove unused variable and fixed style