fixes #5788 - before_destroy missing from EnsureNotUsedBy.new in SmartProxy model