Skip to content

Commit

Permalink
fix(oob): check service is string instance (#814)
Browse files Browse the repository at this point in the history
Signed-off-by: Timo Glastra <[email protected]>
  • Loading branch information
TimoGlastra authored May 31, 2022
1 parent 478fda3 commit bd1e677
Showing 1 changed file with 1 addition and 1 deletion.
Original file line number Diff line number Diff line change
Expand Up @@ -103,7 +103,7 @@ export class OutOfBandInvitation extends AgentMessage {
// TODO: this only takes into account inline didcomm services, won't work for public dids
public getRecipientKeys(): Key[] {
return this.services
.filter((s): s is OutOfBandDidCommService => typeof s !== 'string')
.filter((s): s is OutOfBandDidCommService => typeof s !== 'string' && !(s instanceof String))
.map((s) => s.recipientKeys)
.reduce((acc, curr) => [...acc, ...curr], [])
.map((didKey) => DidKey.fromDid(didKey).key)
Expand Down

0 comments on commit bd1e677

Please sign in to comment.