Support for maxPages to be able to skip possible empty last pages
This commit is contained in:
parent
ea223c3609
commit
783cc42613
@ -66,6 +66,14 @@
|
||||
return self;
|
||||
}
|
||||
|
||||
- (NSInteger) numberOfPages
|
||||
{
|
||||
NSInteger num = [super numberOfPages];
|
||||
id maxPages = _settings[@"maxPages"];
|
||||
|
||||
return maxPages ? MIN(num, [maxPages longValue]) : num;
|
||||
}
|
||||
|
||||
#pragma mark -
|
||||
#pragma mark Callbacks
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user