Skip to content

Commit

Permalink
Merge pull request #183 from humanmade/fix-linter-errors-1-1-2
Browse files Browse the repository at this point in the history
Fix linter errors
  • Loading branch information
Chris Reynolds authored Jan 6, 2021
2 parents 6ffb9e2 + 3cc5a4a commit 19711c5
Show file tree
Hide file tree
Showing 2 changed files with 11 additions and 3 deletions.
2 changes: 1 addition & 1 deletion inc/class-markdownparser.php
Original file line number Diff line number Diff line change
Expand Up @@ -100,7 +100,7 @@ protected function inlineLink( $data ) {
if ( ! empty( $parts['scheme'] ) ) {
$new_url = convert_internal_link( $href );

// Allow shortcircuiting (e.g. for public display)
// Allow shortcircuiting (e.g. for public display).
if ( $new_url === null ) {
$result['element']['name'] = 'span';
$result['element']['attributes'] = [];
Expand Down
12 changes: 10 additions & 2 deletions inc/namespace.php
Original file line number Diff line number Diff line change
Expand Up @@ -129,7 +129,11 @@ function add_docs_for_group( Group $group, string $doc_dir ) : Group {
// Generate objects for each file.
$iterator = new DirectoryIterator( $doc_dir );
foreach ( $iterator as $leaf ) {
/** @var \SplFileInfo $leaf */
/**
* Current iterator file object.
*
* @var \SplFileInfo $leaf
*/
if ( $leaf->isDir() ) {
if ( $leaf->isDot() ) {
continue;
Expand Down Expand Up @@ -175,7 +179,11 @@ function get_page_for_dir( string $dir, string $root_dir ) : ?Page {

$iterator = new DirectoryIterator( $dir );
foreach ( $iterator as $leaf ) {
/** @var \SplFileInfo $leaf */
/**
* Current iterator file object.
*
* @var \SplFileInfo $leaf
*/
if ( $leaf->isDir() ) {
if ( $leaf->isDot() ) {
continue;
Expand Down

0 comments on commit 19711c5

Please sign in to comment.