Use the same network for the apps and the file store

This commit is contained in:
yflory
2017-01-06 13:52:53 +01:00
parent 004d4a16fe
commit 1e70af0c16
6 changed files with 32 additions and 16 deletions

View File

@@ -698,20 +698,21 @@ define([
Cryptpad.alert(Messages.common_connectionLost);
};
var config = {
websocketURL: Cryptpad.getWebsocketURL(),
channel: secret.channel,
readOnly: readOnly,
data: {},
// our public key
validateKey: secret.keys.validateKey || undefined,
//readOnly: readOnly,
crypto: Crypto.createEncryptor(secret.keys),
userName: 'poll',
};
// don't initialize until the store is ready.
Cryptpad.ready(function () {
var config = {
websocketURL: Cryptpad.getWebsocketURL(),
channel: secret.channel,
readOnly: readOnly,
data: {},
// our public key
validateKey: secret.keys.validateKey || undefined,
//readOnly: readOnly,
crypto: Crypto.createEncryptor(secret.keys),
userName: 'poll',
network: Cryptpad.getNetwork()
};
if (readOnly) {
$('#commit, #create-user, #create-option, #publish, #admin').remove();
}