moving shared method into mixin