Since default is 0, which means unlimited it shouldn't throw error:
"You've selected 1 items, but you're only allowed to select 0 items." So when i put it this way:
if ($dropbox_limit !== 0) { // don't count if 0
if (count($dropbox->lineages) > $dropbox_limit) {
form_error($element, t("You've selected %select-count items, but you're only allowed to select %dropbox-limit items.", array('%select-count' => count($dropbox->lineages), '%dropbox-limit' => $dropbox_limit)));
}
}
it works. Is there any problem with this?
Comments
Comment #1
wim leersUgh. I added this last minute and obviously didn't test thoroughly enough. Thanks for reporting!
Please post as a patch next time ;)
Comment #2
Anonymous (not verified) commentedAutomatically closed -- issue fixed for two weeks with no activity.