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

nomics-platform

Package Overview
Dependencies
Maintainers
3
Versions
45
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

nomics-platform - npm Package Compare versions

Comparing version 0.13.5 to 0.13.6

23

lib/audit/test/audit.js

@@ -276,4 +276,7 @@ const au = require('../au')

au.assert(typeof bid0 === 'number' && !isNaN(bid0), 'Expect bid price to be of type number or numeric string')
au.assert(
typeof bid0 === 'number' && !isNaN(bid0),
'Expect bid price to be of type number or numeric string'
)
au.assert(
typeof bid1 === 'number' && !isNaN(bid1),

@@ -288,4 +291,7 @@ 'Expect bid amount to be of type number or numeric string'

au.assert(typeof ask0 === 'number' && !isNaN(ask0), 'Expect ask price to be of type number or numeric string')
au.assert(
typeof ask0 === 'number' && !isNaN(ask0),
'Expect ask price to be of type number or numeric string'
)
au.assert(
typeof ask1 === 'number' && !isNaN(ask1),

@@ -296,4 +302,11 @@ 'Expect ask amount to be of type number or numeric string'

au.assert(
typeof orderBook.bids[0] === typeof orderBook.asks[0],
'Expect ask prices and bid prices to be of the same type'
);
const bidPrices = orderBook.bids.map(b => b[0])
const bidPricesSorted = orderBook.bids.map(b => b[0]).sort((a, b) => b - a)
const bidPricesSorted = typeof orderBook.bids[0][0] === 'number'
? orderBook.bids.map(b => b[0]).sort((a, b) => b - a)
: orderBook.bids.map(b => b[0]).sort((a, b) => b.localeCompare(a));
au.assert(

@@ -305,3 +318,5 @@ JSON.stringify(bidPrices) === JSON.stringify(bidPricesSorted),

const askPrices = orderBook.asks.map(b => b[0])
const askPricesSorted = orderBook.asks.map(b => b[0]).sort((a, b) => a - b)
const askPricesSorted = typeof orderBook.asks[0][0] === 'number'
? orderBook.asks.map(b => b[0]).sort((a, b) => a - b)
: orderBook.asks.map(b => b[0]).sort((a, b) => a.localeCompare(b));
au.assert(

@@ -308,0 +323,0 @@ JSON.stringify(askPrices) === JSON.stringify(askPricesSorted),

2

package.json
{
"name": "nomics-platform",
"version": "0.13.5",
"version": "0.13.6",
"description": "Nomics Platform Toolkit",

@@ -5,0 +5,0 @@ "keywords": [

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