fixing active logic