Moved reusable code into mixin
Added spartan implementation of profiles class