mirror of
https://github.com/waku-org/js-waku.git
synced 2025-02-05 17:14:46 +00:00
Remove dupe code
This commit is contained in:
parent
f2a2233c77
commit
381333347e
@ -19,12 +19,7 @@ export class WakuMessage {
|
|||||||
timestamp: Date = new Date()
|
timestamp: Date = new Date()
|
||||||
): WakuMessage {
|
): WakuMessage {
|
||||||
const payload = Buffer.from(utf8, 'utf-8');
|
const payload = Buffer.from(utf8, 'utf-8');
|
||||||
return new WakuMessage({
|
return WakuMessage.fromBytes(payload, contentTopic, timestamp);
|
||||||
payload,
|
|
||||||
version: DefaultVersion,
|
|
||||||
contentTopic,
|
|
||||||
timestamp: timestamp.valueOf() / 1000,
|
|
||||||
});
|
|
||||||
}
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
|
Loading…
x
Reference in New Issue
Block a user