| @@ -202,10 +202,10 @@ | ||
| 202 | 202 | |
| 203 | 203 | $this->chunk .= $this->getChunk(); |
| 204 | 204 | $this->chunk = $this->read_chunk_xml_nodes($this->chunk); |
| 205 | 205 | |
| 206 | - // only read the first 1mb of file | |
| 207 | - if ($this->is_processing && ($this->record_counter > 0 || ftell($this->getFileHandle()) > $this->process_max_size)) { | |
| 206 | + // only read the first 1mb of file when sampling | |
| 207 | + if ($this->is_processing && ftell($this->getFileHandle()) > $this->process_max_size) { | |
| 208 | 208 | break; |
| 209 | 209 | } |
| 210 | 210 | |
| 211 | 211 | $current_pos = intval(ftell($this->getFileHandle())); |