Skip Menu |

This queue is for tickets about the Data-Page CPAN distribution.

Report information
The Basics
Id: 53475
Status: resolved
Priority: 0/
Queue: Data-Page

People
Owner: Nobody in particular
Requestors: nygel [...] cpan.org
Cc:
AdminCc:

Bug Information
Severity: Normal
Broken in:
  • 2.00
  • 2.01
  • 2.02
Fixed in: 2.04-TRIAL



Subject: entries_on_this_page returns wrong value on non-existent pages
For example, we have 5 entries with a page size of 10, the first page has 5 results, any other page has none.

Example code :

use Data::Page;

my $page = Data::Page->new();
$page->total_entries(5);
$page->entries_per_page(10);
$page->current_page(2);
print $page->entries_on_this_page;

The above returns 5, should return 0 or undef.
cleaning up documentation, and adding a demo test, in 2.04.