Lots o' profile handler refactoring