aboutsummaryrefslogtreecommitdiffstats
path: root/classes/BowelyzerConfig.sc
diff options
context:
space:
mode:
Diffstat (limited to 'classes/BowelyzerConfig.sc')
-rw-r--r--classes/BowelyzerConfig.sc13
1 files changed, 8 insertions, 5 deletions
diff --git a/classes/BowelyzerConfig.sc b/classes/BowelyzerConfig.sc
index b521203..3a3ebe6 100644
--- a/classes/BowelyzerConfig.sc
+++ b/classes/BowelyzerConfig.sc
@@ -98,8 +98,6 @@ BowelyzerConfig{
if(this.readConfigurationFile(configFile).not,{
error("Reading of configuration file failed. Using default.");
config = defaultConfig;
- },{
- configFilePath = configFile;
});
},{
("No configuration file provided. Using default.").postln;
@@ -217,6 +215,7 @@ BowelyzerConfig{
postln("Reading of configuration complete. Now validating...");
if(this.validateConfig,{
postln("Validation complete.");
+ configFilePath = configFile;
^true;
},{
postln("Validation failed.");
@@ -414,10 +413,14 @@ BowelyzerConfig{
// add an input with standard controls to the config
addInput{
- var name = this.createUniqueIdentifier;
- config.at(\inputs).put(name, 0);
+ arg name;
+ var id = this.createUniqueIdentifier;
+ if((name.notNil && (name != "") && config.at(\inputs).includesKey(name).not), {
+ id = name;
+ });
+ config.at(\inputs).put(id, 0);
this.validateConfig;
- ^name;
+ ^id;
}
// create a unique identifier of the form msg[number]