Skip to content

Commit

Permalink
Fixups for JS crypto
Browse files Browse the repository at this point in the history
Signed-off-by: ItalyPaleAle <43508+ItalyPaleAle@users.noreply.github.com>
  • Loading branch information
ItalyPaleAle committed Jun 14, 2023
1 parent df00e20 commit 5b37e32
Show file tree
Hide file tree
Showing 4 changed files with 13 additions and 10 deletions.
2 changes: 1 addition & 1 deletion cryptography/javascript/sdk/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -60,7 +60,7 @@ expected_stdout_lines:
- "== APP == Encrypting federico-di-dio-photography-Q4g0Q-eVVEg-unsplash.jpg to encrypted.out"
- "== APP == Encrypted the message to encrypted.out"
- "== APP == == Decrypting message using streams"
- "== APP == Encrypting encrypted.out to decrypted.out"
- "== APP == Decrypting encrypted.out to decrypted.out.jpg"
- "== APP == Decrypted the message to decrypted.out.jpg"
- "Exited App successfully"
expected_stderr_lines:
Expand Down
3 changes: 2 additions & 1 deletion cryptography/javascript/sdk/crypto-quickstart/index.mjs
Original file line number Diff line number Diff line change
Expand Up @@ -72,7 +72,7 @@ async function encryptDecryptStream(client) {

// Decrypt the message
console.log("== Decrypting message using streams");
console.log("Encrypting encrypted.out to decrypted.out");
console.log("Decrypting encrypted.out to decrypted.out.jpg");
await pipeline(
createReadStream("encrypted.out"),
await client.crypto.decrypt({
Expand All @@ -84,4 +84,5 @@ async function encryptDecryptStream(client) {
console.log("Decrypted the message to decrypted.out.jpg");
}

// Start the code
await start();
15 changes: 8 additions & 7 deletions cryptography/javascript/sdk/crypto-quickstart/package-lock.json

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

3 changes: 2 additions & 1 deletion cryptography/javascript/sdk/crypto-quickstart/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -12,9 +12,10 @@
"author": "",
"license": "MIT",
"dependencies": {
"@dapr/dapr": "3.1.0"
"@dapr/dapr": "3.1.1"
},
"devDependencies": {
"@types/node": "^18.0.0",
"eslint": "^8.42.0"
}
}

0 comments on commit 5b37e32

Please sign in to comment.