Fix error when static dependency disappear in a Rule.