Change firehose code structure