rewrite mixin; now better code quality