Fix double / issue in ExtractTask

Also fix an issue where extracting pot files for plugins ended up creating
a Localedefault.pot file incorrectly.

Fixes #2284
This commit is contained in:
mark_story 2011-11-23 21:03:24 -05:00
parent 07462f0bef
commit 4103fe14a2

View file

@ -162,7 +162,7 @@ class ExtractTask extends Shell {
} else { } else {
$message = __d('cake_console', "What is the path you would like to output?\n[Q]uit", $this->_paths[0] . DS . 'Locale'); $message = __d('cake_console', "What is the path you would like to output?\n[Q]uit", $this->_paths[0] . DS . 'Locale');
while (true) { while (true) {
$response = $this->in($message, null, $this->_paths[0] . DS . 'Locale'); $response = $this->in($message, null, rtrim($this->_paths[0], DS) . DS . 'Locale');
if (strtoupper($response) === 'Q') { if (strtoupper($response) === 'Q') {
$this->out(__d('cake_console', 'Extract Aborted')); $this->out(__d('cake_console', 'Extract Aborted'));
$this->_stop(); $this->_stop();
@ -187,6 +187,7 @@ class ExtractTask extends Shell {
if (empty($this->_files)) { if (empty($this->_files)) {
$this->_searchFiles(); $this->_searchFiles();
} }
$this->_output = rtrim($this->_output, DS) . DS;
$this->_extract(); $this->_extract();
} }