Add to namespaces and prettify.
Remove unused dependency.
Fix error check in handleEnd method.