diff --git a/package.json b/package.json index 8a93df3..b8ec04f 100644 --- a/package.json +++ b/package.json @@ -1,6 +1,6 @@ { "name": "@rollbar/react", - "version": "0.7.1", + "version": "0.7.2", "description": "React features to enhance using Rollbar.js in React Applications", "main": "lib", "module": "dist", diff --git a/src/utils.js b/src/utils.js index d3c3903..ac6dd19 100644 --- a/src/utils.js +++ b/src/utils.js @@ -14,5 +14,6 @@ export function wrapValue(val, defaultAs) { } export function isValidLevel(level) { - return VALID_LEVELS[level] >= constants.LEVEL_DEBUG && VALID_LEVELS[level] <= constants.LEVEL_CRITICAL; + return VALID_LEVELS[level] >= VALID_LEVELS[constants.LEVEL_DEBUG] + && VALID_LEVELS[level] <= VALID_LEVELS[constants.LEVEL_CRITICAL]; }