Improved warning messages when getting or setting a control that

hasn't been defined
main
Mike Lynch 2023-04-15 15:48:28 +10:00
parent 4849ff7a68
commit 61130aa239
1 changed files with 7 additions and 8 deletions

View File

@ -39,18 +39,17 @@ TouchOSC {
} }
v { | url | v { | url |
^if( controls.at(url).isNil.not, { ^if( controls.at(url).isNil.not,
controls.at(url).value { controls.at(url).value },
}, { ("v: No control with url" + url).postln }
nil
); );
} }
v_ { | url, v | v_ { | url, v |
^if( controls.at(url).isNil.not, { ^if( controls.at(url).isNil.not,
controls.at(url).value_(v) { controls.at(url).value_(v) },
}, { ("v_: No control with url" + url).postln }
nil); );
} }
} }