Skip to content

Commit

Permalink
feat: add preimage to transactions (#2868)
Browse files Browse the repository at this point in the history
* feat: add preimage to transactions

* fix: upgrade to 2.6.0

* fix: remove console log

---------

Co-authored-by: Pavan Joshi <[email protected]>
  • Loading branch information
reneaaron and pavanjoshi914 authored Nov 21, 2023
1 parent 4c5e739 commit 4cdb8c8
Show file tree
Hide file tree
Showing 3 changed files with 7 additions and 6 deletions.
2 changes: 1 addition & 1 deletion package.json
Original file line number Diff line number Diff line change
Expand Up @@ -37,7 +37,7 @@
"dependencies": {
"@bitcoin-design/bitcoin-icons-react": "^0.1.10",
"@bitcoinerlab/secp256k1": "^1.0.5",
"@getalby/sdk": "^2.5.0",
"@getalby/sdk": "^2.6.0",
"@headlessui/react": "^1.7.16",
"@lightninglabs/lnc-web": "^0.2.4-alpha",
"@noble/curves": "^1.1.0",
Expand Down
3 changes: 2 additions & 1 deletion src/extension/background-script/connectors/alby.ts
Original file line number Diff line number Diff line change
Expand Up @@ -99,14 +99,15 @@ export default class Alby implements Connector {
custom_records: invoice.custom_records,
id: `${invoice.payment_request}-${index}`,
memo: invoice.comment || invoice.memo,
preimage: "", // alby wallet api doesn't support preimage (yet)
preimage: invoice.preimage,
payment_hash: invoice.payment_hash,
settled: invoice.settled,
settleDate: new Date(invoice.settled_at).getTime(),
totalAmount: invoice.amount,
type: invoice.type == "incoming" ? "received" : "sent",
})
);

return {
data: {
transactions,
Expand Down
8 changes: 4 additions & 4 deletions yarn.lock
Original file line number Diff line number Diff line change
Expand Up @@ -666,10 +666,10 @@
resolved "https://registry.yarnpkg.com/@eslint/js/-/js-8.52.0.tgz#78fe5f117840f69dc4a353adf9b9cd926353378c"
integrity sha512-mjZVbpaeMZludF2fsWLD0Z9gCref1Tk4i9+wddjRvpUNqqcndPkBD09N/Mapey0b3jaXbLm2kICwFv2E64QinA==

"@getalby/sdk@^2.5.0":
version "2.5.0"
resolved "https://registry.yarnpkg.com/@getalby/sdk/-/sdk-2.5.0.tgz#d1b0a22cbcf986755c4b684096d97f52ed0b469d"
integrity sha512-MRLgI6WxCCLgrar+qDqm/UhKs+V6yXzNm4y1bJRAuN72nkKT+TjTJHCmk9GjTngR3FrOfLbeMsPwBxCmbvfrLQ==
"@getalby/sdk@^2.6.0":
version "2.6.0"
resolved "https://registry.yarnpkg.com/@getalby/sdk/-/sdk-2.6.0.tgz#51508c7833b0580575055f15b8fe21567b76288a"
integrity sha512-klD1FrpGY39QldPf00KtzIveWj0dXtgGdZH6nLWdJ0Ness7FAqy2RkgSF7JQfKJeJSFek7Ip3AL/KCT5/lZgww==
dependencies:
crypto-js "^4.1.1"
events "^3.3.0"
Expand Down

0 comments on commit 4cdb8c8

Please sign in to comment.