Permalink
Browse files

Change code flags string access to chartAt

Change code flags string access to chartAt instead of [x] for IE7 compatibility. (extends on #512)
  • Loading branch information...
1 parent 0c38dfd commit 83b76e5dc9ba03debfdeae7e36db6bb45cec79c5 @maritz committed Aug 24, 2012
Showing with 2 additions and 3 deletions.
  1. +2 −3 lib/lexer.js
View
@@ -1,4 +1,3 @@
-
/*!
* Jade - Lexer
* Copyright(c) 2010 TJ Holowaychuk <tj@vision-media.ca>
@@ -475,8 +474,8 @@ Lexer.prototype = {
var flags = captures[1];
captures[1] = captures[2];
var tok = this.tok('code', captures[1]);
- tok.escape = flags[0] === '=';
- tok.buffer = flags[0] === '=' || flags[1] === '=';
+ tok.escape = flags.charAt(0) === '=';
+ tok.buffer = flags.charAt(0) === '=' || flags.charAt(1) === '=';
return tok;
}
},

0 comments on commit 83b76e5

Please sign in to comment.