replaced $ensure with $active boolean