New Case Study:See how Anthropic automated 95% of dependency reviews with Socket.Learn More
Socket
Sign inDemoInstall
Socket

monstrous

Package Overview
Dependencies
Maintainers
1
Versions
12
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

monstrous - npm Package Compare versions

Comparing version

to
0.3.1

7

CHANGELOG.md

@@ -5,2 +5,9 @@ # Changelog

## [0.3.1](https://gitlab.com/monstrous/monstrous/compare/v0.3.0...v0.3.1) (2023-07-26)
### Bug Fixes
* compile order() exprs ([0d1be96](https://gitlab.com/monstrous/monstrous/commit/0d1be9605bb50947434544a1a296c664fc2ea423))
## [0.3.0](https://gitlab.com/monstrous/monstrous/compare/v0.2.0...v0.3.0) (2023-07-16)

@@ -7,0 +14,0 @@

12

lib/statement/index.js

@@ -14,4 +14,4 @@ import pgp from 'pg-promise';

export const $order = {
asc: val => `${val instanceof Expr ? val.sql : val} asc`,
desc: val => `${val instanceof Expr ? val.sql : val} desc`
asc: val => `${val instanceof Expr ? val.compile() : val} asc`,
desc: val => `${val instanceof Expr ? val.compile() : val} desc`
};

@@ -262,3 +262,9 @@

text.push(this.#order.join(', '));
text.push(this.#order.map(o => {
if (o instanceof Expr) {
return o.compile();
}
return o;
}).join(', '));
}

@@ -265,0 +271,0 @@

{
"name": "monstrous",
"version": "0.3.0",
"version": "0.3.1",
"description": "a lightweight SQL composer for Node.js and PostgreSQL",

@@ -5,0 +5,0 @@ "main": "index.js",

@@ -125,3 +125,3 @@ # monstrous

`db.query` runs raw SQL statements. Ordinal arguments may be passed inline, or a map of [named parameters](https://github.com/vitaly-t/pg-promise#named-parameters). A [query target](#query-targets) may be passed as the final argument to specify results handling.
`db.query` runs raw SQL statements. Pass ordinal arguments inline, or use a map of [named parameters](https://github.com/vitaly-t/pg-promise#named-parameters). A [query target](#query-targets) may be passed as the final argument to specify results handling.

@@ -128,0 +128,0 @@ ```javascript