removed redundant isActive check