Add the active flag check