Skip to content
Browse files

throw a 'SyntaxError' instead of 'Error' to match more closely the be…

…havior of Query Selector API
  • Loading branch information...
1 parent c3e4ab9 commit ace7b0b26edd54ffa316e066a06048c204f844d4 @dperini committed Dec 31, 2012
Showing with 2 additions and 2 deletions.
  1. +1 −1 src/nwmatcher-base.js
  2. +1 −1 src/nwmatcher.js
View
2 src/nwmatcher-base.js
@@ -210,7 +210,7 @@
emit =
function(message) {
- if (Config.VERBOSITY) { throw Error(message); }
+ if (Config.VERBOSITY) { throw SyntaxError(message); }
if (global.console && global.console.log) {
global.console.log(message);
}
View
2 src/nwmatcher.js
@@ -827,7 +827,7 @@
// control user notifications
emit =
function(message) {
- if (Config.VERBOSITY) { throw new Error(message); }
+ if (Config.VERBOSITY) { throw new SyntaxError(message); }
if (global.console && global.console.log) {
global.console.log(message);
}

0 comments on commit ace7b0b

Please sign in to comment.
Something went wrong with that request. Please try again.