Conditional deactivate

I am sorry for being unable to use git.
This is a clean PR.
understood