diff --git a/web/app/assets/javascripts/configureTrack.js b/web/app/assets/javascripts/configureTrack.js index 01b32d7c5..c2d9b8fb0 100644 --- a/web/app/assets/javascripts/configureTrack.js +++ b/web/app/assets/javascripts/configureTrack.js @@ -696,7 +696,7 @@ function validateAudioSettings(allowEmptyInput) { var isValid = true; - var noTrackErrMsg = 'You must assign at least one input port to each of your tracks. Please update your settings to correct this.'; + var noTrackErrMsg = 'You can assign no more than 2 input ports to each of your tracks. Please update your settings to correct this.'; var noInstrumentErrMsg = 'You must specify what instrument is being played for each track. Please update your settings to correct this.'; var outputErrMsg = 'You must assign two output ports for stereo session audio to hear music. Please update your settings to correct this.'; @@ -725,12 +725,14 @@ // if Track 2 exists, verify Input and Instrument exist if (isValid) { - if ($('#track2-input > option').size() > 2) { + var track2Count = $('#track2-input > option').size(); + if (track2Count > 2) { errMsg = noTrackErrMsg; isValid = false; } - if (isValid && $('#track2-instrument > option:selected').length === 0) { + // only validate instrument if second track is selected + if (isValid && track2Count > 0 && $('#track2-instrument > option:selected').length === 0) { errMsg = noInstrumentErrMsg; isValid = false; }