cjs-gettext
Advanced tools
Comparing version 1.0.4 to 1.0.5
10
index.js
@@ -67,3 +67,3 @@ /** | ||
/* eslint id-length: 0 */ | ||
var n; | ||
var n, evalResult; | ||
@@ -77,4 +77,10 @@ if ( DEVELOP ) { | ||
if ( data && meta && data[''][msgId] ) { | ||
evalResult = eval('n = ' + value + '; ' + meta.plural); | ||
if ( typeof evalResult === 'boolean' ) { | ||
evalResult = +evalResult; | ||
} | ||
// translation | ||
return data[''][msgId][eval('n = ' + value + '; ' + meta.plural)]; | ||
return data[''][msgId][evalResult]; | ||
} | ||
@@ -81,0 +87,0 @@ |
{ | ||
"name": "cjs-gettext", | ||
"version": "1.0.4", | ||
"version": "1.0.5", | ||
"description": "Application localization tools.", | ||
@@ -23,3 +23,5 @@ "author": { | ||
"keywords": [ | ||
"commonjs", | ||
"cjs", | ||
"sdk", | ||
"cjssdk", | ||
@@ -26,0 +28,0 @@ "framework", |
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
New author
Supply chain riskA new npm collaborator published a version of the package for the first time. New collaborators are usually benign additions to a project, but do indicate a change to the security surface area of a package.
Found 1 instance in 1 package
6948
77
0