#32246 closed task (blessed) (fixed)
Fix a variety of phpDoc issues
Reported by: | DrewAPicture | Owned by: | DrewAPicture |
---|---|---|---|
Milestone: | 4.6 | Priority: | low |
Severity: | normal | Version: | |
Component: | General | Keywords: | |
Focuses: | docs | Cc: |
Description
- Add DocBlocks where missing
- Clarify param/return types where applicable
- Add missing
@since
versions
Attachments (11)
Change History (384)
This ticket was mentioned in Slack in #docs by drew. View the logs.
9 years ago
#74
@
9 years ago
Added 32246.diff which gives two common examples of passing arguments to add_query_arg as well as a note about escaping.
#249
follow-up:
↓ 251
@
9 years ago
We should clarify that media_sideload_image()
can return image URL also, and that HTML tag is default value. Example in a patch.
This ticket was mentioned in Slack in #core-themes by davidakennedy. View the logs.
9 years ago
#251
in reply to:
↑ 249
@
9 years ago
Replying to dimadin:
We should clarify that
media_sideload_image()
can return image URL also, and that HTML tag is default value. Example in a patch.
Can you please create a separate ticket and add your patch there?
This ticket was mentioned in Slack in #core by drew. View the logs.
9 years ago
#301
@
9 years ago
- Resolution fixed deleted
- Status changed from closed to reopened
Meh, #32246 is easy to type with one hand (and remember). Might as well just keep using it ;)
#318
@
9 years ago
@DrewAPicture Can you review my patch please?
Better docs for: WP_Ajax_Response::add()
#319
@
9 years ago
@ramiy on class-wp-ajax-response.php.patch:
- For the
$args
parameter description, "to override the defaults" is a given. Maybe something like this instead: "Optional. An array or string of XML response arguments." - The
$action
argument description should indicate the boolean, i.e. "Whether to use a nonce. Default false." - In descriptions, we use ID vs id
- For
$position
, listing out the accepted values and what they mean is helpful, but the description of what the argument represents is missing. $supplemental
: There should be backticks around<supplemental>
in the description
#320
@
9 years ago
@ramiy: Also, on the $id
and $data
arguments, should mention that they also accept a WP_Error
object and under what circumstances that might be passed. You can be general, but helpful to have more information than simply that these two args can also accept WP_Error
objects. The idea is to explain why :-)
#324
@
9 years ago
New docs for WP_Feed_Cache
, WP_Feed_Cache_Transient
, WP_SimplePie_File
, WP_SimplePie_Sanitize_KSES
classes, in wp-includes/class-feed.php.
Has patch. Needs review (@DrewAPicture).
#325
@
9 years ago
@ramiy: Please create new tickets for specifically-targeted docs fixes. I would say probably a ticket per file would work.
This ticket is sort of a mishmash of stuff we run across now and then, and at 320+ commits/comments and counting, it's not really a great place to upload patches. Loading the page in the browser alone takes a good bit of memory :-)
Let's do separate tickets for targeted fixes by file.
This ticket was mentioned in Slack in #docs by drew. View the logs.
9 years ago
#339
follow-up:
↓ 340
@
9 years ago
37550:
@DrewAPicture I'm not sure that the modified documentation describes the structure of that action.
Here is an example action with type => plugin:
<?php do_action( 'upgrader_process_complete', $this, array( 'action' => 'update', 'type' => 'plugin', 'bulk' => true, 'plugins' => $plugins, ) );
In your modified documentation it looks like:
@type string $plugin
but it should be :
@type array $plugins { Array of bulk item update data. ... ... .. }
Same applies for other types, as all of them placed under a different array key.
#340
in reply to:
↑ 339
@
9 years ago
Replying to nextendweb:
37550:
@DrewAPicture I'm not sure that the modified documentation describes the structure of that action.
Here is an example action with type => plugin:
<?php do_action( 'upgrader_process_complete', $this, array( 'action' => 'update', 'type' => 'plugin', 'bulk' => true, 'plugins' => $plugins, ) );In your modified documentation it looks like:
@type string $pluginbut it should be :
@type array $plugins { Array of bulk item update data. ... ... .. }Same applies for other types, as all of them placed under a different array key.
The documentation was updated based on how core currently implements the hook:
Happy to update if you can provide examples in the wild that consistently use a 'plugins' or 'themes' key.
#341
@
9 years ago
@nextendweb Actually, I take that back. I see what you're getting at. Let's reopen #36875.
#370
@
8 years ago
- Keywords has-patch removed
- Resolution set to fixed
- Status changed from assigned to closed
Closing as fixed as this now has over 300 comments. Follow-up: #37770.
In 32338: