Improve NAMESPACE and onLoad/onUnload