Commit a33d2bea1507a0b2444c5fed8dc6b809e96c0b05

Authored by Megan Watson
1 parent 34a441df

Removed extra unzip code which wasn't working and returning false.

PT: 1821487
Jira: KTC-867

Committed by: Megan Watson
search2/indexing/extractors/OpenXmlTextExtractor.inc.php
@@ -219,6 +219,9 @@ class OpenXmlTextExtractor extends ExternalDocumentExtractor @@ -219,6 +219,9 @@ class OpenXmlTextExtractor extends ExternalDocumentExtractor
219 } 219 }
220 $filename = str_replace('\\','/',$filename); 220 $filename = str_replace('\\','/',$filename);
221 221
  222 + /*
  223 + // Removing the unzip command as the whole document gets unzipped at the start
  224 +
222 $cmd = '"' .$this->unzip . '"' . ' ' . str_replace( 225 $cmd = '"' .$this->unzip . '"' . ' ' . str_replace(
223 array('{source}','{part}', '{target_dir}'), 226 array('{source}','{part}', '{target_dir}'),
224 array($this->sourcefile, $filename,$this->openxml_dir), $this->unzip_params); 227 array($this->sourcefile, $filename,$this->openxml_dir), $this->unzip_params);
@@ -228,6 +231,7 @@ class OpenXmlTextExtractor extends ExternalDocumentExtractor @@ -228,6 +231,7 @@ class OpenXmlTextExtractor extends ExternalDocumentExtractor
228 $this->output = _kt('Failed to execute command: ') . $cmd; 231 $this->output = _kt('Failed to execute command: ') . $cmd;
229 return false; 232 return false;
230 } 233 }
  234 + */
231 235
232 $filename = $this->openxml_dir . "/$filename"; 236 $filename = $this->openxml_dir . "/$filename";
233 if (!file_exists($filename)) 237 if (!file_exists($filename))