Commit a7f9cb3 1 parent a3f211a commit a7f9cb3 Copy full SHA for a7f9cb3
File tree 1 file changed +7
-1
lines changed
1 file changed +7
-1
lines changed Original file line number Diff line number Diff line change @@ -290,14 +290,19 @@ export default class Client {
290
290
return this . publishEnvelope ( {
291
291
contentTopic : topic ,
292
292
message : msgBytes ,
293
+ timestamp,
293
294
} )
294
295
} )
295
296
)
296
297
297
298
return this . decodeMessage ( msgBytes , topics [ 0 ] )
298
299
}
299
300
300
- async publishEnvelope ( env : messageApi . Envelope ) : Promise < void > {
301
+ async publishEnvelope ( env : {
302
+ contentTopic : string
303
+ message : Uint8Array
304
+ timestamp ?: Date
305
+ } ) : Promise < void > {
301
306
const bytes = env . message
302
307
if ( ! env . contentTopic ) {
303
308
throw new Error ( 'Missing content topic' )
@@ -312,6 +317,7 @@ export default class Client {
312
317
{
313
318
contentTopic : env . contentTopic ,
314
319
message : bytes ,
320
+ timestamp : env . timestamp ,
315
321
} ,
316
322
] )
317
323
} catch ( err ) {
You can’t perform that action at this time.
0 commit comments