factory CommandPart.fromJson(Map<String, dynamic> json) => CommandPart( channel: json['channel'] as String, reason: json['reason'] == null ? null : json['reason'] as String, );