refactor: existingexpration to existingexpirationt

in createClosedGroups.ts. Cleaned up some comments
pull/2971/head
William Grant 2 years ago
parent 8838477e34
commit 01d04bd4d3

@ -138,9 +138,6 @@ async function generateUpdateExpirySignature({
}
}
/**
* NOTE if shortenOrExtend is an empty string it means we want to hardcode the expiry to a TTL value, otherwise it's to shorten or extend the TTL
*/
async function generateGetExpiriesSignature({
timestamp,
messageHashes,

@ -3,7 +3,7 @@ const minutes = seconds * 60;
const hours = minutes * 60;
const days = hours * 24;
/** in millisecond */
/** in milliseconds */
export const DURATION = {
/** 1000ms */
SECONDS: seconds,

@ -103,7 +103,7 @@ async function sendToGroupMembers(
groupName: string,
admins: Array<string>,
encryptionKeyPair: ECKeyPair,
existingExprationType: DisappearAfterSendOnly,
existingExpirationType: DisappearAfterSendOnly,
existingExpireTimer: number,
isRetry: boolean = false
): Promise<any> {
@ -113,7 +113,7 @@ async function sendToGroupMembers(
groupName,
admins,
encryptionKeyPair,
existingExprationType,
existingExpirationType,
existingExpireTimer
);
window?.log?.info(`Sending invites for group ${groupPublicKey} to ${listOfMembers}`);
@ -169,7 +169,7 @@ async function sendToGroupMembers(
groupName,
admins,
encryptionKeyPair,
existingExprationType,
existingExpirationType,
existingExpireTimer,
isRetrySend
);
@ -187,7 +187,7 @@ function createInvitePromises(
groupName: string,
admins: Array<string>,
encryptionKeyPair: ECKeyPair,
existingExprationType: DisappearingMessageType,
existingExpirationType: DisappearingMessageType,
existingExpireTimer: number
) {
return listOfMembers.map(async m => {
@ -198,7 +198,7 @@ function createInvitePromises(
admins,
keypair: encryptionKeyPair,
timestamp: Date.now(),
expirationType: existingExprationType,
expirationType: existingExpirationType,
expireTimer: existingExpireTimer,
};
const message = new ClosedGroupNewMessage(messageParams);

Loading…
Cancel
Save