How to permit users to add more items to a multivalue field conditionally? I'm working on a publication management site and need a multivalue field collection (which contains several file upload fields). Our authors can upload multiple versions of their publication but only after reviewers (or managers) allow it. Basically I would like to hide the "add another item" button and show if certain conditions are met.
Just place this in a custom module replacing what is given in CAPITAL letters:

function my_module_form_alter(&amp;$form, &amp;$form_state, $form_id) {
  if ($form_id == 'CONTENT_TYPE_node_form') {
    if (CONDITIONS) {
      unset($form['field_files_collection'][LANGUAGE_NONE]['add_more']);
    }

  }
}