Skip to content

Instantly share code, notes, and snippets.

@arapehl
Created June 15, 2011 16:16
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save arapehl/1027451 to your computer and use it in GitHub Desktop.
Save arapehl/1027451 to your computer and use it in GitHub Desktop.
Defaults parseInt's radix to 10
if (parseInt('080') === 0) {
/*global _parseInt*/
_parseInt = parseInt;
parseInt = function (str, radix) {
return _parseInt(str, radix || 10);
}
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment