Some refactoring
Fixed some formatting
again, formatting.