From 1871d17e657e8e9cac4fa1795116d8ed03ad6df0 Mon Sep 17 00:00:00 2001 From: cel Date: Sun, 11 Aug 2019 20:08:14 -0700 Subject: Render and validate peer-invites --- lib/app.js | 13 ++++--------- 1 file changed, 4 insertions(+), 9 deletions(-) (limited to 'lib/app.js') diff --git a/lib/app.js b/lib/app.js index 7e91dcb..04ad487 100644 --- a/lib/app.js +++ b/lib/app.js @@ -44,15 +44,10 @@ function App(sbot, config) { this.useOoo = conf.ooo == null ? false : conf.ooo this.ssbPort = 8008 this.portRegexp = new RegExp(':' + this.ssbPort + '$') - /* - var capsConfig = config.caps || {} - this.userInviteCap = capsConfig.userInvite - || new Buffer('MxiG/9q04kN2C6vJQKa6ZhAj0G/FdfRkmeGTMnpsoek=', 'base64') - // sha256('user-invites:DEVELOPMENT') - this.peerInviteCap = capsConfig.peerInvite - || new Buffer('pmr+IzM+4VAZgi5H5bOopXkwnzqrNussS7DtAJsfbf0=', 'base64') - // sha256('peer-invites:DEVELOPMENT') - */ + this.caps = config.caps || {} + this.peerInviteCap = this.caps.peerInvite + || new Buffer('HT0wIYuk3OWc2FtaCfHNnakV68jSGRrjRMP9Kos7IQc=', 'base64') // sha256('peer-invites') + this.devPeerInviteCap = new Buffer('pmr+IzM+4VAZgi5H5bOopXkwnzqrNussS7DtAJsfbf0=', 'base64') // sha256('peer-invites:DEVELOPMENT') this.voteBranches = !!config.voteBranches this.hostname = (/:/.test(this.host) ? '[' + this.host + ']' : this.host) + this.port -- cgit v1.2.3