Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Fixups for JS crypto quickstart #883

Merged
merged 2 commits into from
Jun 15, 2023
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
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();

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

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.2"
},
"devDependencies": {
"@types/node": "^18.0.0",
"eslint": "^8.42.0"
}
}