Skip to content

Commit

Permalink
Merge branch 'hotfix/18' into develop
Browse files Browse the repository at this point in the history
Forward port #18
  • Loading branch information
michalbundyra committed May 14, 2019
2 parents 5cba734 + 74fb3da commit 95e282e
Show file tree
Hide file tree
Showing 4 changed files with 25 additions and 0 deletions.
2 changes: 2 additions & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -53,6 +53,8 @@ All notable changes to this project will be documented in this file, in reverse
- `PHP\CorrectClassNameCase` - fixes caps in class/interface names used within the tag,
- `PHP\DisallowFqn` - imports FQN used within the tag.

- [#18](https://github.com/webimpress/coding-standard/pull/18) `Commenting\DocComment` - fixes requiring content straight after doc-block - allows empty line when next content is another doc-block

## 1.0.2 - 2019-05-12

### Added
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -269,6 +269,7 @@ private function checkAfterClose(File $phpcsFile, int $commentStart, int $commen
$allowEmptyLineBefore = [
T_NAMESPACE,
T_USE,
T_DOC_COMMENT_OPEN_TAG,
];

$prev = $phpcsFile->findPrevious(T_WHITESPACE, $commentStart - 1, null, true);
Expand Down
11 changes: 11 additions & 0 deletions test/Sniffs/Commenting/DocCommentUnitTest.inc
Original file line number Diff line number Diff line change
Expand Up @@ -286,4 +286,15 @@ class Foo
}
);
}

/**
* FIRST DOC-BLOCK COMMENT
*/

/**
* Method doc-block
*/
public function allowSpaceBetweenTwoPhpDocBlock()
{
}
}
11 changes: 11 additions & 0 deletions test/Sniffs/Commenting/DocCommentUnitTest.inc.fixed
Original file line number Diff line number Diff line change
Expand Up @@ -288,4 +288,15 @@ $c = 'xyz';
}
);
}

/**
* FIRST DOC-BLOCK COMMENT
*/

/**
* Method doc-block
*/
public function allowSpaceBetweenTwoPhpDocBlock()
{
}
}

0 comments on commit 95e282e

Please sign in to comment.