Skip to content
This repository has been archived by the owner on Oct 30, 2018. It is now read-only.

Commit

Permalink
Merge pull request #130 from braydonf/pubkeyindex
Browse files Browse the repository at this point in the history
Add index for user on pubkeys
  • Loading branch information
pgerbes1 authored Sep 27, 2017
2 parents 7044dd2 + 80de77c commit 25182b1
Showing 1 changed file with 2 additions and 0 deletions.
2 changes: 2 additions & 0 deletions lib/models/pubkey.js
Original file line number Diff line number Diff line change
Expand Up @@ -31,6 +31,8 @@ var PublicKey = new mongoose.Schema({
}
});

PublicKey.index({user: 1});

PublicKey.plugin(SchemaOptions, {
read: 'secondaryPreferred'
});
Expand Down

0 comments on commit 25182b1

Please sign in to comment.