The documentation page for Drupal 7 reports parameters that are not used from the function.
I think the description of the parameters is still from the Drupal 6 version of the function.
| Comment | File | Size | Author |
|---|---|---|---|
| #16 | 819476-15-D6.patch | 1.34 KB | jhodgdon |
| #15 | book-form-update-fix-D6.patch | 1.39 KB | rdrh555 |
| #11 | 819476-newdocblock.patch | 1.37 KB | jhodgdon |
| #10 | 819476_remove_parameters_description_fix_return_description.patch | 879 bytes | avpaderno |
| #6 | 819476_remove_parameters_description_fix_return_value.patch | 726 bytes | avpaderno |
Comments
Comment #1
avpadernoI am fixing a typo in the title.
Comment #2
avpadernoActually, also the documentation for Drupal 6 reports the same parameters, but the function declaration doesn't include them (see http://api.drupal.org/api/function/book_form_update/7, and http://api.drupal.org/api/function/book_form_update/6).
Comment #3
jhodgdonGood catch! Looks like both D7 and D6 docs need the @param sections removed.
This would be a good project for a novice contributor.
Comment #4
avpadernoThis is the patch for Drupal 7. Looking at the description for the return value, I am not sure it's correct.
Comment #5
jhodgdonIt looks to me as though the return value is the rendered select element for the parent page. I don't think it's worded very well in the @return. Care to fix it?
Comment #6
avpadernoLet's see if this works.
Comment #7
jhodgdonHmmm. I can't get this patch to apply for me, although it's passing the tests. I believe there is already a @return segment in the file, and your patch isn't including it as context or -- lines?
Comment #8
avpadernoYou are right. The patch includes the new description for @return, but the patch doesn't mark it correctly.
Probably I didn't clean the local copy of the files, before to create the new patch.
Comment #9
avpadernoI thought I re-rolled the patch, but it seems I forgot. I will do it in the next minutes.
Comment #10
avpadernoComment #11
jhodgdonThanks, that looks like a better patch.
Hmmm... This is the result:
So... the above patch is fine, as far as it goes, but maybe we can make the whole doc block better while we're at it?
Comment #12
avpadernoThis is decisively better. I didn't change the description of the function as I was not 100% sure in which cases it was called.
Comment #13
dries commentedCommitted to CVS HEAD. Thanks.
Comment #14
jhodgdonWe should port this one to Drupal 6.
Comment #15
rdrh555 commentedThe Drupal 6 version
Comment #16
jhodgdonLooks good, except there is an extra space at the end of this line:
+ * This function is called via AJAX when the selected book is changed on a node
Here's the same patch with the space removed (and removed the Eclipse stuff at the top, since I needed to do that to make it apply in my Eclipse workspace).
Comment #17
gábor hojtsyCommitted, thanks.