Improve code readability by flattening logic tree
Merge pull request #19 from bear24rw/readability

Improve code readability by flattening logic tree