Mercurial > hg > webaudioevaluationtool
changeset 3103:d79b9939b19e
Fix for no <calibration>
author | Nicholas Jillings <n.g.r.jillings@se14.qmul.ac.uk> |
---|---|
date | Thu, 18 Jan 2018 17:06:52 +0000 |
parents | 972b55d81c1b |
children | 7820ce4a96c0 |
files | js/specification.js |
diffstat | 1 files changed, 3 insertions(+), 2 deletions(-) [+] |
line wrap: on
line diff
--- a/js/specification.js Thu Jan 18 10:12:12 2018 +0000 +++ b/js/specification.js Thu Jan 18 17:06:52 2018 +0000 @@ -131,8 +131,9 @@ this[attributeName] = projectAttr; } } - - this.calibration.decode(this, projectXML.getElementsByTagName('calibration')[0]); + if (projectXML.getElementsByTagName('calibration').length > 0) { + this.calibration.decode(this, projectXML.getElementsByTagName('calibration')[0]); + } var exitTextNode = setupNode.getElementsByTagName('exitText'); if (exitTextNode.length == 1) {