summaryrefslogtreecommitdiffstats
path: root/lib
diff options
context:
space:
mode:
authorAaron O'Mullan <aaron.omullan@friendco.de>2014-03-31 01:34:37 -0700
committerAaron O'Mullan <aaron.omullan@friendco.de>2014-03-31 01:34:37 -0700
commitd18da55a184ef514cb996e731830cd0749ccdfe9 (patch)
treeae8894ebc0bc94e11fe5765f30a6f7d44f91b1f0 /lib
parent7ab78b420a2805084b74078aa7db3fac903046fd (diff)
downloadgitbook-d18da55a184ef514cb996e731830cd0749ccdfe9.zip
gitbook-d18da55a184ef514cb996e731830cd0749ccdfe9.tar.gz
gitbook-d18da55a184ef514cb996e731830cd0749ccdfe9.tar.bz2
Improve section classification
Diffstat (limited to 'lib')
-rw-r--r--lib/page.js4
1 files changed, 2 insertions, 2 deletions
diff --git a/lib/page.js b/lib/page.js
index 7288fb9..047f3e4 100644
--- a/lib/page.js
+++ b/lib/page.js
@@ -38,9 +38,9 @@ function parsePage(src) {
section.type = sectionType(section);
return section;
})
- .map(function(section) {
+ .map(function(section, idx) {
// Transform given type
- if(section.type === 'exercise') {
+ if(section.type === 'exercise' && (idx % 2) == 1) {
return {
type: section.type,
};