From b4467570d303351b3c8e7bafdce19d90d48236f9 Mon Sep 17 00:00:00 2001 From: Yusuf Taiwo Hassan Date: Tue, 28 May 2024 18:23:29 +0100 Subject: [PATCH] doc: clean up docs and include extraFields and Lint --- packages/message/__tests__/store/publish.test.ts | 6 +++--- packages/message/src/store/impl.ts | 2 +- packages/message/src/store/types.ts | 2 +- 3 files changed, 5 insertions(+), 5 deletions(-) diff --git a/packages/message/__tests__/store/publish.test.ts b/packages/message/__tests__/store/publish.test.ts index c07ee821..10fcf9ad 100644 --- a/packages/message/__tests__/store/publish.test.ts +++ b/packages/message/__tests__/store/publish.test.ts @@ -16,13 +16,13 @@ describe('Store message publish', () => { const extraFields: Record = { key1: 'value1', key2: 123, - }; + } const hash = await store.send({ channel: 'TEST', account: account, fileObject: fileContent, - extraFields + extraFields, }) const response = await store.download(hash.content.item_hash) @@ -31,7 +31,7 @@ describe('Store message publish', () => { const expected = 'y' expect(got).toBe(expected) - expect(hash.content.extra_fields).toEqual(extraFields); + expect(hash.content.extra_fields).toEqual(extraFields) }) it('should pin a file and retrieve it correctly', async () => { diff --git a/packages/message/src/store/impl.ts b/packages/message/src/store/impl.ts index 3842dac4..34e506ef 100644 --- a/packages/message/src/store/impl.ts +++ b/packages/message/src/store/impl.ts @@ -66,7 +66,7 @@ export class StoreMessageClient { item_type: storageEngine, item_hash: hash, time: timestamp, - extra_fields: extraFields + extra_fields: extraFields, } const builtMessage = buildStoreMessage({ diff --git a/packages/message/src/store/types.ts b/packages/message/src/store/types.ts index f7e270c3..bb9cb18e 100644 --- a/packages/message/src/store/types.ts +++ b/packages/message/src/store/types.ts @@ -45,7 +45,7 @@ export type StorePinConfiguration = { * * inlineRequested: If set to False, the Store message will be store on the same storageEngine you picked. * - * apiServer: The API server endpoint used to carry the request to the Aleph's network. + * extraFields: Extra fields to add to the Store message. * * sync: If true, the function will wait for the message to be confirmed by the API server. */