diff options
author | Hakim El Hattab | 2019-04-10 10:09:41 +0200 |
---|---|---|
committer | Hakim El Hattab | 2019-04-10 10:09:41 +0200 |
commit | 32197bd77d079ca77b42340e3c2da6812c9cc174 (patch) | |
tree | 36e53d8490abb124e1e80dcab949b6018ee80270 | |
parent | 9aa514bc7087f98028a978ca843ff07054e31d9e (diff) |
fix numeric presence condition
-rw-r--r-- | plugin/highlight/highlight.js | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/plugin/highlight/highlight.js b/plugin/highlight/highlight.js index 9dacd6f..e50676f 100644 --- a/plugin/highlight/highlight.js +++ b/plugin/highlight/highlight.js @@ -141,7 +141,7 @@ c:[{cN:"comment",b:/\(\*/,e:/\*\)/},e.ASM,e.QSM,e.CNM,{b:/\{/,e:/\}/,i:/:/}]}}); block.parentNode.appendChild( fragmentBlock ); RevealHighlight.highlightLines( fragmentBlock ); - if( fragmentIndex ) { + if( typeof fragmentIndex === 'number' ) { fragmentBlock.setAttribute( 'data-fragment-index', fragmentIndex ); fragmentIndex += 1; } |