Optimization

removal of redundancies within conditional's, unnecessary return statements, fixed typo's, and other miscellaneous hacks.