fixes console error module selector (#1543)

Co-authored-by: Rishabh Shukla <42492389+blurry-x-face@users.noreply.github.com>
Co-authored-by: Harsh Khandeparkar <34770591+HarshKhandeparkar@users.noreply.github.com>
Co-authored-by: Jeffrey Warren <jeff@unterbahn.com>
This commit is contained in:
SHUBHAM SHARMA
2021-09-14 20:01:46 +05:30
committed by GitHub
parent aa1feb0b37
commit f2a696a3c4

View File

@@ -17,7 +17,6 @@ function DefaultHtmlSequencerUi(_sequencer, options) {
// look up needed steps from Url Hash: // look up needed steps from Url Hash:
function importStepsFromUrlHash() { function importStepsFromUrlHash() {
var hash = urlHash.getUrlHashParameter('steps'); var hash = urlHash.getUrlHashParameter('steps');
if (hash) { if (hash) {
_sequencer.importString(hash); _sequencer.importString(hash);
_sequencer.run({ index: 0 }); _sequencer.run({ index: 0 });
@@ -27,9 +26,7 @@ function DefaultHtmlSequencerUi(_sequencer, options) {
function selectNewStepUi() { function selectNewStepUi() {
var m = $(addStepSel + ' select').val(); var m = $(addStepSel + ' select').val();
//if so that whenever the module dropdown is empty it will not show error it will take first value. if(m) $(addStepSel + ' .info').html(_sequencer.modulesInfo(m).description);
if(!m) m = arguments[0];
else $(addStepSel + ' .info').html(_sequencer.modulesInfo(m).description);
$(addStepSel + ' #add-step-btn').prop('disabled', false); $(addStepSel + ' #add-step-btn').prop('disabled', false);
} }