Refactored some of the flow control in Splitter.node_split to reduce the amount of indentation.