@openreceive/http 0.4.17 → 0.4.19
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/dist/adapter-surface.js
CHANGED
|
@@ -290,11 +290,11 @@ function paymentInsert(input) {
|
|
|
290
290
|
// src/sql-payments.ts
|
|
291
291
|
import { randomUUID } from "crypto";
|
|
292
292
|
import {
|
|
293
|
+
OPENRECEIVE_ATTEMPT_EXPIRY_GRACE_SECONDS as OPENRECEIVE_ATTEMPT_EXPIRY_GRACE_SECONDS2,
|
|
293
294
|
OPENRECEIVE_PAYMENTS_SCHEMA_VERSION,
|
|
294
295
|
paymentsDdlStatements,
|
|
295
|
-
|
|
296
|
-
|
|
297
|
-
redactSecrets
|
|
296
|
+
redactSecrets,
|
|
297
|
+
unixSeconds as unixSeconds2
|
|
298
298
|
} from "@openreceive/core";
|
|
299
299
|
|
|
300
300
|
// src/sql-adapters.ts
|
|
@@ -509,10 +509,10 @@ function createSqlPayments(db, options = {}) {
|
|
|
509
509
|
const statement = (sql) => adapter.dialect === "postgres" ? toPgPlaceholders(sql) : sql;
|
|
510
510
|
const lockReference = async (tx, reference) => {
|
|
511
511
|
if (adapter.dialect === "postgres") {
|
|
512
|
-
await tx.query(
|
|
513
|
-
|
|
514
|
-
ADVISORY_LOCK_SEED
|
|
515
|
-
|
|
512
|
+
await tx.query(
|
|
513
|
+
statement("SELECT 1 AS locked FROM pg_advisory_xact_lock(hashtextextended(?, ?))"),
|
|
514
|
+
[reference, ADVISORY_LOCK_SEED]
|
|
515
|
+
);
|
|
516
516
|
}
|
|
517
517
|
};
|
|
518
518
|
const rowsForReference = async (tx, reference) => {
|
package/dist/index.js
CHANGED
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@openreceive/http",
|
|
3
|
-
"version": "0.4.
|
|
3
|
+
"version": "0.4.19",
|
|
4
4
|
"description": "Node.js HTTP routes and payment storage for Bitcoin Lightning checkout, with optional USDT, USDC, SOL and ETH swaps.",
|
|
5
5
|
"keywords": [
|
|
6
6
|
"bitcoin",
|
|
@@ -17,8 +17,8 @@
|
|
|
17
17
|
"main": "./dist/index.js",
|
|
18
18
|
"types": "./dist/index.d.ts",
|
|
19
19
|
"dependencies": {
|
|
20
|
-
"@openreceive/core": "0.4.
|
|
21
|
-
"@openreceive/node": "0.4.
|
|
20
|
+
"@openreceive/core": "0.4.19",
|
|
21
|
+
"@openreceive/node": "0.4.19"
|
|
22
22
|
},
|
|
23
23
|
"exports": {
|
|
24
24
|
".": {
|