@voiceflow/common 8.3.1 → 8.3.2

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -16,10 +16,10 @@ const replaceVariables = (phrase, variables, modifier = undefined, { trim = true
16
16
  return phrase.replace(constants_1.READABLE_VARIABLE_REGEXP, (match, inner) => String((0, exports.variableReplacer)(match, inner, variables, modifier)));
17
17
  };
18
18
  exports.replaceVariables = replaceVariables;
19
- // turn float variables to 2 decimal places
19
+ // turn float variables to 4 decimal places
20
20
  const sanitizeVariables = (variables) => Object.entries(variables).reduce((acc, [key, value]) => {
21
21
  if (typeof value === 'number' && !Number.isInteger(value)) {
22
- acc[key] = value.toFixed(2);
22
+ acc[key] = value.toFixed(4);
23
23
  }
24
24
  else {
25
25
  acc[key] = value;
@@ -11,10 +11,10 @@ export const replaceVariables = (phrase, variables, modifier = undefined, { trim
11
11
  }
12
12
  return phrase.replace(READABLE_VARIABLE_REGEXP, (match, inner) => String(variableReplacer(match, inner, variables, modifier)));
13
13
  };
14
- // turn float variables to 2 decimal places
14
+ // turn float variables to 4 decimal places
15
15
  export const sanitizeVariables = (variables) => Object.entries(variables).reduce((acc, [key, value]) => {
16
16
  if (typeof value === 'number' && !Number.isInteger(value)) {
17
- acc[key] = value.toFixed(2);
17
+ acc[key] = value.toFixed(4);
18
18
  }
19
19
  else {
20
20
  acc[key] = value;
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@voiceflow/common",
3
- "version": "8.3.1",
3
+ "version": "8.3.2",
4
4
  "description": "Junk drawer of utility functions",
5
5
  "keywords": [
6
6
  "voiceflow"
@@ -60,5 +60,5 @@
60
60
  "publishConfig": {
61
61
  "access": "public"
62
62
  },
63
- "gitHead": "9230c46040e3891d8bbed75b171dbc4f0ea07e3d"
63
+ "gitHead": "eb8d92af87448d5f34d648d0e1e48992c42ec289"
64
64
  }