# HG changeset patch # User Nicholas Jillings # Date 1492182245 -3600 # Node ID 52224b9d6e8bd6b18bd5f8ce75a55ff7c81da6fd # Parent 2dfc19a33bbc1fccd44ff407b3b7b97f5e52c1b7 Undefined vs null conditional checks in core.js diff -r 2dfc19a33bbc -r 52224b9d6e8b js/core.js --- a/js/core.js Fri Apr 14 16:02:52 2017 +0100 +++ b/js/core.js Fri Apr 14 16:04:05 2017 +0100 @@ -1202,7 +1202,7 @@ // Get the data from Specification var pagePool = []; for (var page of specification.pages) { - if (page.position !== null || page.alwaysInclude) { + if (page.position !== undefined || page.alwaysInclude) { page.alwaysInclude = true; } pagePool.push(page) @@ -1215,7 +1215,7 @@ // Now get the order of pages var fixed = [] for (var page of pagePool) { - if (page.position !== null) { + if (page.position !== undefined) { fixed.push(page); var i = pagePool.indexOf(page); pagePool.splice(i, 1);