Static code analysis with Php Inspections (EA Extended): dead code dropped, couple bugs fixed

This commit is contained in:
Vladimir Reznichenko 2017-03-03 17:35:37 +01:00
parent cb12e323a5
commit e1773ee2b8
4 changed files with 2 additions and 4 deletions

View File

@ -94,6 +94,6 @@ class TimeZoneTransformer extends Transformer
return 'Etc/GMT'.($hours !== 0 ? $signal.$hours : ''); return 'Etc/GMT'.($hours !== 0 ? $signal.$hours : '');
} }
throw new \InvalidArgumentException('The GMT time zone \'%s\' does not match with the supported formats GMT[+-]HH:MM or GMT[+-]HHMM.'); throw new \InvalidArgumentException(sprintf("The GMT time zone '%s' does not match with the supported formats GMT[+-]HH:MM or GMT[+-]HHMM.", $formattedTimeZone));
} }
} }

View File

@ -162,7 +162,6 @@ class Process
$this->setTimeout($timeout); $this->setTimeout($timeout);
$this->useFileHandles = '\\' === DIRECTORY_SEPARATOR; $this->useFileHandles = '\\' === DIRECTORY_SEPARATOR;
$this->pty = false; $this->pty = false;
$this->enhanceWindowsCompatibility = true;
$this->enhanceSigchildCompatibility = '\\' !== DIRECTORY_SEPARATOR && $this->isSigchildEnabled(); $this->enhanceSigchildCompatibility = '\\' !== DIRECTORY_SEPARATOR && $this->isSigchildEnabled();
$this->options = array_replace(array('suppress_errors' => true, 'binary_pipes' => true), $options); $this->options = array_replace(array('suppress_errors' => true, 'binary_pipes' => true), $options);
} }

View File

@ -206,7 +206,7 @@ class DigestData
} elseif ('auth' === $this->elements['qop']) { } elseif ('auth' === $this->elements['qop']) {
$digest .= ':'.$this->elements['nc'].':'.$this->elements['cnonce'].':'.$this->elements['qop']; $digest .= ':'.$this->elements['nc'].':'.$this->elements['cnonce'].':'.$this->elements['qop'];
} else { } else {
throw new \InvalidArgumentException('This method does not support a qop: "%s".', $this->elements['qop']); throw new \InvalidArgumentException(sprintf('This method does not support a qop: "%s".', $this->elements['qop']));
} }
$digest .= ':'.$a2Md5; $digest .= ':'.$a2Md5;

View File

@ -61,7 +61,6 @@ abstract class AbstractOperation implements OperationInterface
$this->source = $source; $this->source = $source;
$this->target = $target; $this->target = $target;
$this->result = new MessageCatalogue($source->getLocale()); $this->result = new MessageCatalogue($source->getLocale());
$this->domains = null;
$this->messages = array(); $this->messages = array();
} }