diff --git a/package.json b/package.json index 06a572a297..dedfd9009d 100644 --- a/package.json +++ b/package.json @@ -5,8 +5,8 @@ "version": "1.15.0", "license": "GPL-3.0", "author": { - "name": "Oxen Labs", - "email": "team@oxen.io" + "name": "Session Foundation", + "email": "contact@session.foundation" }, "repository": { "type": "git", diff --git a/ts/receiver/dataMessage.ts b/ts/receiver/dataMessage.ts index bc6c253dd3..5be3402acb 100644 --- a/ts/receiver/dataMessage.ts +++ b/ts/receiver/dataMessage.ts @@ -46,8 +46,7 @@ function cleanAttachments(decryptedDataMessage: SignalService.DataMessage) { // Here we go from binary to string/base64 in all AttachmentPointer digest/key fields - // we do not care about group on Session Desktop - + // we do not care about the group field on Session Desktop decryptedDataMessage.group = null; // when receiving a message we get keys of attachment as buffer, but we override the data with the decrypted string instead. diff --git a/ts/receiver/receiver.ts b/ts/receiver/receiver.ts index 8816d8d061..0eb2b3828c 100644 --- a/ts/receiver/receiver.ts +++ b/ts/receiver/receiver.ts @@ -167,7 +167,7 @@ async function handleRequestDetail( envelope.messageHash = messageHash; try { - // NOTE: Annoyngly we add plaintext to the cache + // NOTE: Annoyingly we add plaintext to the cache // after we've already processed some of it (thus the // need to handle senderIdentity separately)... perfStart(`addToCache-${envelope.id}`); diff --git a/ts/session/apis/snode_api/getNetworkTime.ts b/ts/session/apis/snode_api/getNetworkTime.ts index aa052003e0..e22051787c 100644 --- a/ts/session/apis/snode_api/getNetworkTime.ts +++ b/ts/session/apis/snode_api/getNetworkTime.ts @@ -6,41 +6,8 @@ import { isNumber } from 'lodash'; -import { BatchRequests } from './batchRequest'; -import { Snode } from '../../../data/types'; -import { NetworkTimeSubRequest } from './SnodeRequestTypes'; import { NetworkTime } from '../../../util/NetworkTime'; -const getNetworkTime = async (snode: Snode): Promise => { - const subRequest = new NetworkTimeSubRequest(); - - const result = await BatchRequests.doUnsignedSnodeBatchRequestNoRetries( - [subRequest], - snode, - 10000, - null, - false - ); - if (!result || !result.length) { - window?.log?.warn(`getNetworkTime on ${snode.ip}:${snode.port} returned falsy value`, result); - throw new Error('getNetworkTime: Invalid result'); - } - - const firstResult = result[0]; - - if (firstResult.code !== 200) { - window?.log?.warn('Status is not 200 for getNetworkTime but: ', firstResult.code); - throw new Error('getNetworkTime: Invalid status code'); - } - - const timestamp = firstResult?.body?.timestamp; - if (!timestamp) { - throw new Error(`getNetworkTime returned invalid timestamp: ${timestamp}`); - } - GetNetworkTime.handleTimestampOffsetFromNetwork('getNetworkTime', timestamp); - return timestamp; -}; - function handleTimestampOffsetFromNetwork(_request: string, snodeTimestamp: number) { if (snodeTimestamp && isNumber(snodeTimestamp) && snodeTimestamp > 1609419600 * 1000) { // first january 2021. Arbitrary, just want to make sure the return timestamp is somehow valid and not some crazy low value @@ -50,6 +17,5 @@ function handleTimestampOffsetFromNetwork(_request: string, snodeTimestamp: numb } export const GetNetworkTime = { - getNetworkTime, handleTimestampOffsetFromNetwork, }; diff --git a/ts/session/utils/libsession/libsession_utils_multi_encrypt.ts b/ts/session/utils/libsession/libsession_utils_multi_encrypt.ts index cc75b22a3a..287359721e 100644 --- a/ts/session/utils/libsession/libsession_utils_multi_encrypt.ts +++ b/ts/session/utils/libsession/libsession_utils_multi_encrypt.ts @@ -5,7 +5,7 @@ import { /** * Try to decrypt the content with any type of encryption domains we know. - * Does not throw, will return null if we couldn't decrypt it successfuly. + * Does not throw, will return null if we couldn't decrypt it successfully. */ async function multiDecryptAnyEncryptionDomain({ encoded, diff --git a/ts/state/onboarding/ducks/registration.ts b/ts/state/onboarding/ducks/registration.ts index ef52f4bacd..24dbeff6f7 100644 --- a/ts/state/onboarding/ducks/registration.ts +++ b/ts/state/onboarding/ducks/registration.ts @@ -27,7 +27,7 @@ export enum AccountRestoration { Finished, /** we failed to fetch account details in time, so we enter it manually */ DisplayName, - /** we have restored successfuly, show the conversation screen */ + /** we have restored successfully, show the conversation screen */ Complete, } diff --git a/ts/test/session/unit/sending/PendingMessageCache_test.ts b/ts/test/session/unit/sending/PendingMessageCache_test.ts index 4ade1eaa3b..ad9028ff8f 100644 --- a/ts/test/session/unit/sending/PendingMessageCache_test.ts +++ b/ts/test/session/unit/sending/PendingMessageCache_test.ts @@ -299,7 +299,7 @@ describe('PendingMessageCache', () => { Buffer.compare(message.plainTextBuffer, addedMessage.plainTextBuffer) === 0; expect(buffersCompare).to.equal(true, 'buffers were not loaded properly from database'); - // Compare all other valures + // Compare all other values const trimmedAdded = _.omit(addedMessage, ['plainTextBuffer', 'plainTextBufferHex']); const trimmedRebuilt = _.omit(message, ['plainTextBuffer', 'plainTextBufferHex']);