Broke controller logic into seperate mixin.