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

mf-parser

Package Overview
Dependencies
Maintainers
0
Versions
73
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

mf-parser - npm Package Compare versions

Comparing version 3.2.8 to 3.3.0

4

lib/src/parse.js

@@ -217,6 +217,6 @@ "use strict";

} while (ascii !== 125 && this.i <= this.mf.length); // closing curly bracket
if (substring.match(/^[\d,]+$/)) {
if (substring.match(/^[0-9.,]+$/)) {
return substring.split(',').map(Number);
}
throw new MFError(this.mf, this.i, 'Curly brackets should contain only number and comma');
throw new MFError(this.mf, this.i, 'Curly brackets should contain only number, dot and comma');
}

@@ -223,0 +223,0 @@ getParenthesisCharge(ascii) {

@@ -22,3 +22,3 @@ "use strict";

'.': '˙',
',': '˙',
',': '˒',
};

@@ -25,0 +25,0 @@ exports.subscript = {

{
"name": "mf-parser",
"version": "3.2.8",
"version": "3.3.0",
"description": "Parse a molecular formula",

@@ -29,3 +29,3 @@ "main": "lib/src/index.js",

},
"gitHead": "4dddbfbe7419d995ed5c2b5aaa32d1987ef3aa71"
"gitHead": "4348a705339e89ccb27f80459be87ce2d5053e69"
}

@@ -234,3 +234,3 @@ /* eslint-disable unicorn/prefer-code-point */

} while (ascii !== 125 && this.i <= this.mf.length); // closing curly bracket
if (substring.match(/^[\d,]+$/)) {
if (substring.match(/^[0-9.,]+$/)) {
return substring.split(',').map(Number);

@@ -241,3 +241,3 @@ }

this.i,
'Curly brackets should contain only number and comma',
'Curly brackets should contain only number, dot and comma',
);

@@ -244,0 +244,0 @@ }

@@ -19,3 +19,3 @@ export const superscript = {

'.': '˙',
',': '˙',
',': '˒',
};

@@ -22,0 +22,0 @@

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

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