mf-generator
Advanced tools
Comparing version 0.5.9 to 0.5.10
{ | ||
"name": "mf-generator", | ||
"version": "0.5.9", | ||
"version": "0.5.10", | ||
"description": "", | ||
@@ -21,9 +21,9 @@ "main": "src/index.js", | ||
"dependencies": { | ||
"chemical-elements": "^0.5.9", | ||
"mf-finder": "^0.5.9", | ||
"mf-matcher": "^0.5.9", | ||
"mf-parser": "^0.5.9", | ||
"mf-utilities": "^0.5.9", | ||
"chemical-elements": "^0.5.10", | ||
"mf-finder": "^0.5.10", | ||
"mf-matcher": "^0.5.10", | ||
"mf-parser": "^0.5.10", | ||
"mf-utilities": "^0.5.10", | ||
"sum-object-keys": "^1.0.2" | ||
} | ||
} |
@@ -120,4 +120,4 @@ 'use strict'; | ||
// we need to calculate based on the mf but not very often ... | ||
var mf = new MF(mfString); | ||
var info = mf.getInfo(); | ||
let mf = new MF(mfString); | ||
let info = mf.getInfo(); | ||
ems[mfString] = { | ||
@@ -143,6 +143,6 @@ em: info.monoisotopicMass, | ||
for (var i = 0; i < parts.length; i++) { | ||
var part = parts[i][currents[i]]; | ||
for (let i = 0; i < parts.length; i++) { | ||
let part = parts[i][currents[i]]; | ||
if (part) { | ||
var info = getMonoisotopicMass(part); | ||
let info = getMonoisotopicMass(part); | ||
charge += info.charge; | ||
@@ -179,7 +179,7 @@ em += info.em; | ||
for (var ionization of ionizations) { | ||
for (let ionization of ionizations) { | ||
var result = getEMFromParts(keys, currents, ionization); | ||
let result = getEMFromParts(keys, currents, ionization); | ||
var match = matcher(result, filter); | ||
let match = matcher(result, filter); | ||
if (!match) return; | ||
@@ -190,5 +190,5 @@ result.ms = match; | ||
var comments = []; | ||
for (var i = 0; i < keys.length; i++) { | ||
var key = keys[i][currents[i]]; | ||
let comments = []; | ||
for (let i = 0; i < keys.length; i++) { | ||
let key = keys[i][currents[i]]; | ||
if (key) { | ||
@@ -220,4 +220,4 @@ if (key.indexOf('$') > -1) { | ||
var mfs = []; | ||
for (var i = 0; i < parts.length; i++) { | ||
var part = parts[i]; | ||
for (let i = 0; i < parts.length; i++) { | ||
let part = parts[i]; | ||
if (!~part.search(/[0-9]-[0-9]/)) { | ||
@@ -258,4 +258,4 @@ position++; | ||
function getMF(mfs, currents, comment) { | ||
var mf = ''; | ||
for (var i = 0; i < mfs.length; i++) { | ||
let mf = ''; | ||
for (let i = 0; i < mfs.length; i++) { | ||
if (currents[i] === 0) { | ||
@@ -283,6 +283,6 @@ // TODO we need to remove from currents[i] till we reach another part of the MF | ||
function removeMFLastPart(mf) { | ||
var parenthesis = 0; | ||
var start = true; | ||
for (var i = mf.length - 1; i >= 0; i--) { | ||
var ascii = mf.charCodeAt(i); | ||
let parenthesis = 0; | ||
let start = true; | ||
for (let i = mf.length - 1; i >= 0; i--) { | ||
let ascii = mf.charCodeAt(i); | ||
@@ -289,0 +289,0 @@ if (ascii > 96 && ascii < 123) { // lowercase |
17107
Updatedchemical-elements@^0.5.10
Updatedmf-finder@^0.5.10
Updatedmf-matcher@^0.5.10
Updatedmf-parser@^0.5.10
Updatedmf-utilities@^0.5.10