Cleaning up redundant code and long lines
Merge pull request #1793 from multikatt/cleanup

Cleaning up redundant code and long lines