Removing default values when creating a new channel

This commit is contained in:
WolverinDEV 2020-12-04 12:32:28 +01:00
parent 0eb9bb61e8
commit 373c9bb80f

View file

@ -109,6 +109,20 @@ export function createChannelModal(connection: ConnectionHandler, channel: Chann
delete properties["channel_flag_default"];
}
if(!channel) {
/* Delete the default values */
if(properties["channel_flag_maxfamilyclients_unlimited"]) {
delete properties["channel_flag_maxfamilyclients_unlimited"];
delete properties["channel_flag_maxfamilyclients_inherited"];
delete properties["channel_maxfamilyclients"];
}
if(properties["channel_flag_maxclients_unlimited"]) {
delete properties["channel_flag_maxclients_unlimited"];
delete properties["channel_maxclients"];
}
}
callback(properties, updated); //First may create the channel
});