diff --git a/ckanext/odsh/templates/organization/snippets/organization_form.html b/ckanext/odsh/templates/organization/snippets/organization_form.html
index 9af3071d05d20e58e06a036dd51033e83d8204b7..77797c54474261d77eb83b6675013d97b46769e3 100644
--- a/ckanext/odsh/templates/organization/snippets/organization_form.html
+++ b/ckanext/odsh/templates/organization/snippets/organization_form.html
@@ -63,11 +63,12 @@
   
     {# Add a max of 3 empty columns #}
     {% set total_extras = data.extras|count %}
+    {% if total_extras <= (custom_extras|count) %}{% set total_extras = (custom_extras|count) %}{% endif %}
     {% set empty_extras = (limit or 3) - total_extras %}
     {% if empty_extras <= 0 %}{% set empty_extras = 1 %}{% endif %}
   
     {% for extra in range(total_extras, total_extras + empty_extras) %}
-      {% set index = loop.index0 + (data.extras|count) + (custom_extras|count) %}
+      {% set index = loop.index0 + total_extras %}
       {% set prefix = 'extras__%d__' % index %}
       {{ form.custom(
         names=(prefix ~ 'key', prefix ~ 'value', prefix ~ 'deleted'),