Skip to content

Commit b2d4528

Browse files
authored
Merge pull request #30 from BitGo/add-keyid-field
[BG-8805] add keyid field to db schema
2 parents 438ec3b + 3cba7d0 commit b2d4528

File tree

2 files changed

+4
-0
lines changed

2 files changed

+4
-0
lines changed

app/admin.js

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -200,12 +200,15 @@ const saveKeys = co(function *(keys, type) {
200200
return;
201201
}
202202

203+
204+
203205
const keyDocs = keys
204206
.filter( key => validateKey(key, type))
205207
.map( key => ({
206208
type: type,
207209
pub: key.pub,
208210
path: key.path,
211+
keyid: key.keyid,
209212
keyCount: 0
210213
}));
211214

app/models/masterkey.js

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -7,6 +7,7 @@ const masterKeySchema = new mongoose.Schema({
77
customerId: { type: String },
88
pub: { type: String },
99
path: { type: String },
10+
keyid: {type: String},
1011
keyCount: { type: Number }
1112
});
1213

0 commit comments

Comments
 (0)