refactored code to one-lines where it made sense

Signed-off-by: Andrew Deitrick <ajdeitrick@gmail.com>