[TASK] General code cleaning

I found some typos and unused variables.