ChannelManager.fromList constructor
ChannelManager.fromList(
- List<
ServerChannel> channels, - dynamic payload
Implementation
factory ChannelManager.fromList(List<ServerChannel> channels, payload) {
return ChannelManager(
Map<Snowflake, ServerChannel>.from(channels.fold({}, (value, element) {
return {...value, element.id: element};
})),
payload);
}