Skip to content

Commit 1d39995

Browse files
author
Wes Biggs
committed
Realign with spec proposal
1 parent a4850ff commit 1d39995

File tree

2 files changed

+5
-5
lines changed

2 files changed

+5
-5
lines changed

dsnp/profileResource.spec.ts

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -11,11 +11,11 @@ describe("Profile Resource Schema", () => {
1111
const parsed = avro.parse(profileResourceSchema);
1212
const obj = {
1313
type: 1,
14-
cid: Buffer.from("01551220a948904f2f0f479b8f8197694b30184b0d2ed1c1cd2a1ec0fb85d299a192a447", "hex"),
14+
contentHash: Buffer.from("1e203a0393e3ee6c6fec1b13885763225fd0927884b2d431ed262899523ade281cb4", "hex"),
1515
length: 300,
1616
};
1717
const buf = parsed.toBuffer(obj);
18-
expect(buf).toHaveLength(40);
18+
expect(buf).toHaveLength(38);
1919
const output = parsed.fromBuffer(buf);
2020
expect(output).toMatchObject(obj);
2121
});

dsnp/profileResource.ts

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -10,14 +10,14 @@ export default {
1010
doc: "Type of resource",
1111
},
1212
{
13-
name: "cid",
13+
name: "contentHash",
1414
type: "bytes",
15-
doc: "Content IDentifier of resource",
15+
doc: "Multihash digest of resource content",
1616
},
1717
{
1818
name: "length",
1919
type: "int",
20-
doc: "Length of document in bytes",
20+
doc: "Length of resource in bytes",
2121
},
2222
],
2323
};

0 commit comments

Comments
 (0)