Fixed indentations and removed unused variables