Closed (duplicate)
Project:
Drupal core
Version:
9.2.x-dev
Component:
node system
Priority:
Normal
Category:
Task
Assigned:
Unassigned
Reporter:
Created:
1 Oct 2012 at 23:24 UTC
Updated:
12 Apr 2021 at 05:44 UTC
Jump to comment: Most recent, Most recent file
Comments
Comment #0.0
lars toomre commentedAdded tags to Related issues title.
Comment #1
lars toomre commentedAdded a patch at #1313980-71: Clean up API docs for node module that is focused on docblock corrections and modifications. Once that has been committed, my plan is to add a patch here that adds missing type hinting to @param and @return directives as appropriate.
Comment #2
lars toomre commentedAttached is a patch that adds type hinting to the hook examples in node.api.php. This is untested locally, but should pass since all of the changes are in comments. Let's see what the bot thinks.
Comment #2.0
lars toomre commentedCorrected the issue tags.
Comment #3
xjm(Merging "node system" and "node.module" components for 8.x; disregard.)
Comment #4
Jalandhar commentedPatch no longer applies. It needs reroll.
Comment #5
Jalandhar commentedThere is an inconsistency in the addition of type hinting in node.api.php file. Fixed the issues related to it and updating the patch.
Comment #6
mile23Comment #7
mile23Amazingly, the patch in #5 still applies.
It doesn't catch all the needed type hints, though.
Comment #8
adci_contributor commentedPlease review
Comment #9
mile23Thanks.
So, it's the whole module we're dealing with, not just the api file.
phpcs says to have a look in:
Comment #10
mile23Reroll of #8, plus a bunch more work.
This should get all missing parameter hints.
Comment #11
mile23Comment #12
mile23Comment #13
nitvirus commentedPatch is working.
Comment #15
no_angel commentedComment #16
no_angel commentedComment #17
no_angel commentedComment #18
mile23Reroll of #10, plus one error I found.
Based on the gist in the issue summary, no remaining @param or @return type hinting errors.
Comment #19
mile23As with the other issues for the parent meta, moving this to 8.0.x. Patch still applies cleanly.
Comment #25
idebr commentedReroll against 8.6.x.
Fixed the following sniffs in the Node module:
Comment #31
quietone commentedThis work is now being done by sniff. The work here is now in #3207949: Fix Drupal.Commenting.FunctionComment.MissingParamType so closing this as a duplicate. I've identified credit to add over there, let me know if I got it wrong.