Skip Menu |

This queue is for tickets about the MorboDB CPAN distribution.

Report information
The Basics
Id: 74113
Status: resolved
Priority: 0/
Queue: MorboDB

People
Owner: Nobody in particular
Requestors: 'spro^^*%*^6ut# [...] &$%*c
Cc:
AdminCc:

Bug Information
Severity: (no value)
Broken in: (no value)
Fixed in: (no value)



Subject: Misuse of length on array
$ ack 'length\s*\(\s*@' lib/MorboDB/Cursor.pm 399: splice(@docs, $self->_limit, length(@docs) - $self->_limit) length() only applies to scalars, so length(@docs) will evaluate @docs in scalar context, which returns the number of elements. That number will be passed to length(), which will tell you how many digits there are. So you just end up using the wrong number in the calculations. You just need: splice(@docs, $self->_limit, @docs - $self->_limit)
Sorry about the delay. I actually fixed it a long time ago but I guess I forgot to upload a new release. I have released it now, should be live on CPAN in a few hours.