Closed (fixed)
Project:
Drupal core
Version:
8.0.x-dev
Component:
documentation
Priority:
Normal
Category:
Bug report
Assigned:
Unassigned
Reporter:
Created:
6 Mar 2014 at 21:09 UTC
Updated:
29 Jul 2014 at 23:25 UTC
Jump to comment: Most recent, Most recent file
Comments
Comment #1
longwaveGot a bit carried away, and added missing docblocks (of which there were many!) to \Drupal\Core\Database\Query\Select. Most of them are just @inheritdoc but the ones that deal with HAVING clauses needed copying and amending from ConditionInterface.
Comment #2
longwaveActually I wonder if those having* functions should be moved to SelectInterface?
Comment #3
jhodgdonThanks for getting carried away! Looks great!
I just noticed a couple of things, and then we can get this in:
a) core/lib/Drupal/Core/Database/Query/Select.php
This could say @return array ?
b) same class
This should say @return $this with no docs on the next line. Same on havingIsNull(), havingIsNotNull(), havingExists(), havingNotExists(). That's kind of a new standard:
https://drupal.org/node/1354#types
c) same class
No @return here?
d) And regarding #2, it looks like both Select and SelectExtender implement that interface, and SelectExtender does not currently have all those methods, so not all of them can be moved to the interface. The ones that are already on SelectExtender are probably OK to move.
Comment #4
jhodgdonAnd one other thing, if you change code and not just docs, we'll need to get extra reviewers and move this to the database component.
Comment #5
longwave#3.c is a bug, see #2213297: Select::havingCompile() should not return a value
Comment #6
longwaveFixed #3.a and #3.b.
#3.c is unchanged - I don't see the point in documenting it returns NULL for now, because really that return statement should removed in the above linked issue.
#3.d I left alone as well, as I don't fully understand the implications of moving to the interface, and that seems even further out of scope than everything else I fixed here.
Comment #7
jhodgdonAgreed. Looks good!
Comment #8
jhodgdonPatch no longer applies :(
Comment #9
Alumei commentedRe-roll.
Comment #11
Alumei commentedRe-rolled again.
Comment #12
jhodgdonThanks for the reroll (and thanks again for the earlier patch)! Looks like a clean reroll, committed to 8.x.
longwave: it was your fix to that other issue about the having method that broke your patch here. ;)
Comment #14
jhodgdondoh! testbot that is because I already committed the patch!