Improved self-data module and use module.uri

https://bugzilla.mozilla.org/show_bug.cgi?id=875776