fix #493 dispose resources providers

When unloading a class, resources providers instances created at load were not disposed.