File tree Expand file tree Collapse file tree 1 file changed +2
-2
lines changed
src/tutorials/0005-regular-files-api Expand file tree Collapse file tree 1 file changed +2
-2
lines changed Original file line number Diff line number Diff line change @@ -37,7 +37,7 @@ const validate = async (result, ipfs) => {
37
37
}
38
38
39
39
if ( result instanceof Uint8Array ) {
40
- let isEqual = ( new TextEncoder ( ) ) . encode ( 'You did it!' ) . every ( ( elem , idx ) => {
40
+ let isEqual = new TextEncoder ( ) . encode ( 'You did it!' ) . every ( ( elem , idx ) => {
41
41
return elem === result [ idx ]
42
42
} )
43
43
if ( isEqual ) {
@@ -83,7 +83,7 @@ const run = async () => {
83
83
// Using the dir subdirectory CID and file path relative to it:
84
84
// const bufferedContents = await toBuffer(ipfs.cat("/ipfs/QmPT14mWCteuybfrfvqas2L2oin1Y2NCbwzTh9cc33GM1r/success.txt"))
85
85
86
- return new TextDecoder.decode(bufferedContents)
86
+ return new TextDecoder() .decode(bufferedContents)
87
87
}
88
88
return run
89
89
`
You can’t perform that action at this time.
0 commit comments