Skip to content

Various minor fixes.#514

Merged
GaryJones merged 1 commit intodevelopfrom
feature/various-minor-fixes
Jan 8, 2016
Merged

Various minor fixes.#514
GaryJones merged 1 commit intodevelopfrom
feature/various-minor-fixes

Conversation

@jrfnl
Copy link
Copy Markdown
Contributor

@jrfnl jrfnl commented Jan 7, 2016

  • Stay in line with core: page titles now use H1, not H2.
  • Fix incorrect concatenation for translated strings.
  • Improved variable names and remove superfluous condition - see Variable admin notices based on user level. #507.
  • Use local variable instead of global where available.
  • Re-sync the bulk_install() method with the core bulk_upgrade() method.
  • Correct and clarify the documentation for the example function.
  • Fix two wrong text domain slugs in the example file.

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Move non-tagged content above the PHPDoc tags.

Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Added the @internal tag now as the comment does not make sense if moved up.

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

For an internal note, it should use the inline format. See https://github.com/phpDocumentor/fig-standards/blob/master/proposed/phpdoc.md#78-internal . Note the double-closing }.

Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I'll adjust. All the same: the {} annotation is a quite recent change and hasn't been in use that long. Secondly the PSR is still in concept phase, so subject to change and as the annotation is a change, it may well change back to how it always used to be used, i.e. without the {}.

Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Adjusted all other occurrences of @internal as well.

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

phpDocumentor, naturally (same developer), already follows the same format: http://www.phpdoc.org/docs/latest/references/phpdoc/tags/internal.html.

https://github.com/WordPress/WordPress/blob/master/wp-includes/shortcodes.php#L17-L20 is one instance of the format in WP core, though they are other formats too that have not have been fixed up yet.

@jrfnl jrfnl force-pushed the feature/various-minor-fixes branch from ed668be to b7c5023 Compare January 7, 2016 21:08
* Stay in line with core: page titles now use H1, not H2.
* Fix incorrect concatenation for translated strings.
* Improved variable names and remove superfluous condition - see #507.
* Use local variable instead of global where available.
* Re-sync the bulk_install() method with the core bulk_upgrade() method.
* Use {..}} annotation for all comments tagged with @internal.
* Correct and clarify the documentation for the example function.
* Fix two wrong text domain slugs in the example file.
@jrfnl jrfnl force-pushed the feature/various-minor-fixes branch from b7c5023 to 88da3fb Compare January 8, 2016 00:53
GaryJones added a commit that referenced this pull request Jan 8, 2016
@GaryJones GaryJones merged commit 5dbb017 into develop Jan 8, 2016
@GaryJones GaryJones deleted the feature/various-minor-fixes branch January 8, 2016 11:50
@GaryJones GaryJones added this to the 2.6.0 milestone Jan 8, 2016
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants