Secure your code as it's written. Use Snyk Code to scan source code in minutes - no build needed - and fix issues immediately.
const expectMatchingPublicIdentities = (identityA: string, identityB: string) => expect(
_deserializePublicIdentity(identityA),
).to.deep.equal(
_deserializePublicIdentity(identityB),
);
const expectMatchingPublicIdentities = (identityA: string, identityB: string) => expect(
_deserializePublicIdentity(identityA),
).to.deep.equal(
_deserializePublicIdentity(identityB),
);
const toPublicIdentity = async (identity): Promise => {
const publicIdentity = await getPublicIdentity(identity);
return (_deserializePublicIdentity(publicIdentity): any);
};
const toPublicIdentities = (list): Promise> => Promise.all(list.map(toPublicIdentity));
const deserializedIdentities = publicIdentities.map(i => _deserializePublicIdentity(i));
const { permanentIdentities, provisionalIdentities } = _splitProvisionalAndPermanentPublicIdentities(deserializedIdentities);
const deserializedIdentities = (sharingOptions.shareWithUsers || []).map(i => _deserializePublicIdentity(i));
const deserializedIdentitiesWithSelf = this._handleShareWithSelf(deserializedIdentities, shareWithSelf);