bug fix chunked