remove unused variables
align 'end' with 'def'
rename variable inside block
Merge pull request #2178 from fabianrbz/remove_warnings