adds limit param to set number of results#1
adds limit param to set number of results#1dvdokkum wants to merge 2 commits intochartbeat-labs:masterfrom
Conversation
There was a problem hiding this comment.
Are you trying to check if 'limit' is defined on the configService object? This seems to specifically just check that configService.limit is not the value NaN. You'd probably want to do just a generic truthy check, since i imagine the limit should never be set to 0 legitimately? Could also just check that typeof limit is 'number'.
|
Thanks for the help @bowman224, updated with what I think is the more standard method...? |
There was a problem hiding this comment.
Did you try this out? I dont think all params are added to the configService. Alternatively you could do
if ($routeParams.limit) {
limits[host] = $routeParams.limit;
}
There was a problem hiding this comment.
Also, alternatively you could extend DEFAULT_LIMIT to $routeParams.limit
Set the number of Top Pages to return using '&limit=XX' in the URL. Useful for displays with a portrait orientation.