Browse Source

Merge branch 'development' of ssh://ledger-git.dyne.org:2240/CoBox/cobox-config into development

Kieran Gibb 2 years ago
parent
commit
0ea5ab9a70
No known key found for this signature in database
1 changed files with 2 additions and 3 deletions
  1. 2
    3
      index.js

+ 2
- 3
index.js View File

@@ -8,10 +8,8 @@ const constants = require('cobox-constants')
8 8
 const { loadParentKey, saveParentKey } = require('./lib/keys')
9 9
 
10 10
 const CONFIG_FILE = 'config.yml'
11
-const IDENTITY_SUBKEY_ID = 0
12 11
 
13 12
 module.exports = (storage, opts) => new CoBoxConfig(storage, opts)
14
-module.exports.IDENTITY_SUBKEY_ID = IDENTITY_SUBKEY_ID
15 13
 
16 14
 const KeyHandler = require('./lib/handlers/keys')
17 15
 const MapHandler = require('./lib/handlers/map')
@@ -47,7 +45,8 @@ class CoBoxConfig {
47 45
     saveParentKey(this.root, parentKey)
48 46
 
49 47
     this.deriveKeyPair = crypto.keyPair.bind(null, parentKey)
50
-    this.identity = crypto.keyPair(parentKey, IDENTITY_SUBKEY_ID)
48
+    this.logger = logger(path.join(this.root, 'logs', logfile))
49
+    this.log = this.logger('cobox-config')
51 50
 
52 51
     this.groups = KeyHandler(this._groups)
53 52
     this.replicators = KeyHandler(this._replicators)