only deregister if an instance was found