Closed (outdated)
Project:
Drupal core
Version:
6.x-dev
Component:
base system
Priority:
Normal
Category:
Bug report
Assigned:
Unassigned
Issue tags:
Reporter:
Created:
4 Jun 2008 at 05:19 UTC
Updated:
2 Mar 2016 at 22:18 UTC
Jump to comment: Most recent, Most recent file
Comments
Comment #1
dropcube commentedThe patch fixes this, so RTBC.
Comment #2
dropcube commentedOh, didn't change the element in both pager_query and theme('pager', ...). Now I get notice: Undefined offset: 10 in \wwwroot\drupal7\includes\pager.inc
Comment #3
merlinofchaos commentedTry this version.
Comment #4
dropcube commentedOk, It now works with $element > 0 .
Comment #5
Anonymous (not verified) commentedWhy use !isset in one place and empty in another? Can we be consistent and use the same test?
Comment #6
catchStilll applies against HEAD, rerolled with isset().
Comment #7
catchCode style error.
Comment #8
sunEven the first patch from 2008 passed. ;)
Comment #9
webchickYes. Now let's get some tests so this doesn't ever break again.
Comment #10
webchicktagging.
Comment #11
merlinofchaos commentedI can't believe this issue, a 4 line patch, has been sitting for 15 months, because it was sent into the 'needs work' wasteland over a philosophy issue. earnie, WTF. Seriously. Thank you for standing in the way of a perfectly useful fix.
And tests? Why the hell is this notice fix being held up on tests?
Comment #12
merlinofchaos commentedPutting back to needs review so that somebody might actually see this before 2011.
Comment #14
Anonymous (not verified) commented@merlinofchaos: Really, it isn't me if you read the comments after mine. And it appears you need to fix the issues for the testbot.
Result Failed: Failed to apply patch.Comment #15
merlinofchaos commentedearnie, you set it needs work in comment #5 June 2008 and no one even saw this again until May of 2009, so don't tell me it wasn't you. You took a perfectly valid patch and set it 'needs work' because you wanted to see isset() instead of !empty(). 'needs work' means nobody else will ever look at it.
in 2008 there was no testbot. Frankly, I think you should go fix the tests. It's your fault that a useful fix has sat for 15 months. The only reason I went to look for the issue is that I noticed that I still have this patch against one of my dev sites.
Comment #16
damien tournoud commentedRanting surely helps getting things done.
Comment #17
merlinofchaos commentedDamien: Well, it got someone else to actually see it, which is something. Of course, the stupid patch doesn't apply now, it appears. Sigh.
Comment #18
sunSeriously, I have no idea how to test this.
pager_load_array() is only used internally by pager.inc itself, as far as Drupal core is concerned. The second fix from the original patch for pager_query() already went in as part of another patch, so the PagerDefault query extender already sets an unset $element now.
Since the previous condition equaled empty() and not !isset(), I'm using empty() in this patch. !isset() would only work for NULL, not for empty strings or the like.
Comment #19
sunSeems like no one else has an idea how to test this. Can we get it in?
Comment #20
dries commentedCommitted! Finally. ;-)
Comment #22
pdrake commentedThis notice also occurs in D6. Attached is a patch for D6 containing the fix committed in D7.
Comment #23
Peter Bowey commentedRefer #22
This 'needed' fix is still not present in the latest D6 Pressflow 6.25!
I have not verified if it exists in Drupal D6 6.25 [non-Pressflow]
It is now the 25th April 2012 ;-)
Hi @DavidStrauss, @FourKitchens
Comment #24
Rhino-new commentedStill not available in Pressflow, thank goodness I found it here.