Permalink
Browse files

Fixed bug #19913 : Running phpcs in interactive mode causes warnings

  • Loading branch information...
1 parent 0ac892b commit 3711fdae4cd5c782725a3e5a4029cabc467b1f95 @gsherwood gsherwood committed May 6, 2013
Showing with 8 additions and 0 deletions.
  1. +6 −0 CodeSniffer.php
  2. +2 −0 package.xml
View
@@ -1016,6 +1016,12 @@ public function populateTokenListeners()
);
foreach ($this->listeners as $listenerClass) {
+ // Account for a second run through this method, which happens
+ // in interactive mode.
+ if (is_object($listenerClass) === true) {
+ $listenerClass = get_class($listenerClass);
+ }
+
// Work out the internal code for this sniff. Detect usage of namespace
// separators instead of underscores to support PHP namespaces.
if (strstr($listenerClass, '\\') === false) {
View
@@ -37,6 +37,8 @@ http://pear.php.net/dtd/package-2.0.xsd">
-- Thanks to Maik Penz for the patch
- Fixed bug #19892 : ELSE with no braces causes incorrect SWITCH break statement indentation error
- Fixed bug #19908 : PEAR MultiLineCondition Does Not Apply elseif
+ - Fixed bug #19913 : Running phpcs in interactive mode causes warnings
+ -- Thanks to Harald Franndorfer for the patch
</notes>
<contents>
<dir name="/">

0 comments on commit 3711fda

Please sign in to comment.