🚀 Socket Launch Week Day 5:Introducing Repository Access Permissions and Custom Roles.Learn more
Sign In

@reddb-io/client

Package Overview
Dependencies
Maintainers
1
Versions
204
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

@reddb-io/client - npm Package Compare versions

Comparing version
1.20.0-rc.183
to
1.20.0-rc.187
+1
-1
package.json
{
"name": "@reddb-io/client",
"version": "1.20.0-rc.183",
"version": "1.20.0-rc.187",
"description": "Thin remote-only RedDB driver. Downloads the `red_client` binary on install. Speaks RedWire/gRPC/HTTP. Embedded URIs (memory://, file://, red:///path) are rejected — use @reddb-io/sdk for those.",

@@ -5,0 +5,0 @@ "type": "module",

@@ -12,3 +12,3 @@ import { RedDBError } from './protocol.js'

const result = await this.db.query(
`INSERT INTO ${sqlIdentifierPath(collection)} DOCUMENT (body) VALUES (${sqlJsonLiteral(document)}) RETURNING *`,
`INSERT INTO ${sqlIdentifierPath(collection)} DOCUMENT VALUES (${sqlJsonInlineLiteral(document)}) RETURNING *`,
)

@@ -117,2 +117,8 @@ const item = result.rows?.[0]

// ADR 0067 (#1709): a document body is written as an inline strict-JSON
// literal (no surrounding quotes) — the quoted-string coercion is removed.
function sqlJsonInlineLiteral(value) {
return JSON.stringify(value)
}
function sqlValueLiteral(value) {

@@ -119,0 +125,0 @@ if (value == null) return 'NULL'