If you try to pass limit as option to getPopulars o to getAllWithCount, the limit is not used, and with getAll the limit is used. I think that limit is useful in this other 2 cases, because if not you are limited to app_tags_limit configuration in case of getPopulars, or you are not able to limit with getAllWithCount.
Im my case, I need sometimes to have several cloud tag with diferent number of items in each case.
To solve this you need to change getAllWithCount adding the control for the option limit. Change:
if ($c == null)
{
$c = new Criteria();
}
if (isset($options['model']))
{
$c->add(TaggingPeer::TAGGABLE_MODEL, $options['model']);
}
with:
if ($c == null)
{
$c = new Criteria();
}
if (isset($options['limit']))
{
$c->setLimit($options['limit']);
}
if (isset($options['model']))
{
$c->add(TaggingPeer::TAGGABLE_MODEL, $options['model']);
}
In this case, if you pass a option limit, this takes precedence over the configurated value. I think this will be useful for other people.