diff --git a/src/names.js b/src/names.js index 9d95abc..7394e51 100644 --- a/src/names.js +++ b/src/names.js @@ -46,4 +46,11 @@ Names.registerSubDomain = function(name, address, callback) { return this.currentNameSystems.registerSubDomain(name, address, callback); }; +Names.register = function(name, callback) { + if (!this.currentNameSystems) { + throw new Error(this.noProviderError); + } + return this.currentNameSystems.register(name, callback); +}; + export default Names;