hasSlashCommand property Null safety
Whether this group contains any slash commands.
These might not be direct children, and can be nested multiple layers for this method to return true.
Implementation
bool get hasSlashCommand {
return children.any((child) {
if (child is Command) {
return child.type != CommandType.textOnly || child.hasSlashCommand;
}
return child.hasSlashCommand;
});
}