Huge News!Announcing our $40M Series B led by Abstract Ventures.Learn More
Socket
Sign inDemoInstall
Socket

cafe-query

Package Overview
Dependencies
Maintainers
1
Versions
7
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

cafe-query - npm Package Compare versions

Comparing version 1.0.1 to 1.1.0

jsconfig.json

11

index.js

@@ -1,2 +0,2 @@

function CafeQueryError(message) {
function CafeQueryError(message, code) {
this.name = 'CafeQueryError'

@@ -9,2 +9,11 @@ this.message = message

return {
expectNone: async (query, ...values) => {
const [rows] = await dataSource.query(query, values)
if (!rows) {
throw new CafeQueryError('Expected no results, got falsy value')
}
if (rows.length !== 0) {
throw new CafeQueryError('Expected no results, got length: ' + rows.length)
}
},
findOne: async (query, ...values) => {

@@ -11,0 +20,0 @@ const [rows] = await dataSource.query(query, values)

2

package.json
{
"name": "cafe-query",
"version": "1.0.1",
"version": "1.1.0",
"description": "",

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

SocketSocket SOC 2 Logo

Product

  • Package Alerts
  • Integrations
  • Docs
  • Pricing
  • FAQ
  • Roadmap
  • Changelog

Packages

npm

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc