Refactored a bit here a bit there..