{%- assign contributors = site.data.CONTRIBUTORS %} {%- assign nr = include.nr | default: 5 %} {%- if include.custom %} {%- assign allcontributors = include.custom | split: ", " | sort %} {%- else %} {%- for page in site.pages %} {%- if page.contributors and page.search_exclude != true %} {%- assign pagecontr = page.contributors | join: ", " %} {%- if allcontrstr %} {%- assign allcontrstr = allcontrstr | append: ", " | append: pagecontr %} {%- else %} {%- assign allcontrstr = allcontrstr | append: pagecontr %} {%- endif %} {%- endif %} {%- endfor %} {%- for contr in contributors %} {%- assign allcontrstr = allcontrstr | append: ", " | append: contr[0] %} {%- endfor %} {%- assign allcontributors = allcontrstr | split: ", " | uniq | sort %} {%- endif %} {%- endif %}