forgot to add try ... catch back into the code

This commit is contained in:
Peter J. Kohler 2021-01-31 18:03:18 -05:00
parent 2c5a45e90d
commit b038c66370

View File

@ -123,7 +123,7 @@ jsPsych.plugins['virtual-chinrest'] = (function() {
} }
plugin.trial = function(display_element, trial) { plugin.trial = function(display_element, trial) {
/*try {*/ try {
if ( !( trial.blindspot_reps > 0 ) && ( (trial.resize_units == "deg" ) || (trial.resize_units == "degrees" ) ) ) { if ( !( trial.blindspot_reps > 0 ) && ( (trial.resize_units == "deg" ) || (trial.resize_units == "degrees" ) ) ) {
throw Error("Blindspot repetitions set to 0, so resizing to degrees of visual angle is not possible!") throw Error("Blindspot repetitions set to 0, so resizing to degrees of visual angle is not possible!")
} else { } else {
@ -296,9 +296,9 @@ jsPsych.plugins['virtual-chinrest'] = (function() {
jsPsych.pluginAPI.cancelAllKeyboardResponses(); jsPsych.pluginAPI.cancelAllKeyboardResponses();
}) })
} }
/*} catch (e) { } catch (e) {
console.error(e) console.error(e)
}*/ }
}; };
(function ( distanceSetup, $ ) { // jQuery short-hand for $(document).ready(function() { ... }); (function ( distanceSetup, $ ) { // jQuery short-hand for $(document).ready(function() { ... });