Bugzilla – Bug 1967
BrowseDB not keeping last selection for Artists and Albums
Last modified: 2005-08-13 00:23:26 UTC
I believe its due to the new contributor.role array. the selection key gets created and then includes an array ref. This ref isn't the same ref on re-entering so the lastSelection just gets lost and the hash grows without limit. This is after just a bit of browsing: $VAR1 = { 'genre,artist,album,track:0:' => 9, 'artist,album,track:0:contributor.role=ARRAY(0x9c1ef58)' => 4, 'age,track:0:' => 3, 'album,track:0:contributor.role=ARRAY(0xa288554)' => 13, 'album,track:0:contributor.role=ARRAY(0x94cea58)' => 1, 'artist,album,track:0:contributor.role=ARRAY(0x94ce2d8)' => 5, 'album,track:0:contributor.role=ARRAY(0x94c9d30)' => 10, 'album,track:0:contributor.role=ARRAY(0x9aedeb8)' => 13, 'album,track:0:contributor.role=ARRAY(0x9aede4c)' => 8, 'album,track:0:contributor.role=ARRAY(0xa01a700)' => 6 }; I think the right thing here must be to check for the ref and dereference. it seems to work, but maybe I'm not getting all of the right data. patch coming shortly.
Created attachment 720 [details] dereference selection arrays
Looks good.
ok, comitted at change 3957. it works, but I'm a bit lost on where the array ref suddenly appeared when the dereference just shows a single number
It's being interpreted as a scalar value. You should use join('', @{$v}) instead.. sorry about that.
ah ok, right....contributor role 1 and 5. thanks