private void internalOnBindViewHolder(@NonNull final RecyclerView.ViewHolder holder,
                                          final int position, final List<Object> payloads) {

        int currentPos = 0;

        for (final Map.Entry<String, Section> entry : sections.entrySet()) {
            final Section section = entry.getValue();

            // ignore invisible sections
            if (!section.isVisible()) {
                continue;
            }

            final int sectionTotal = section.getSectionItemsTotal();

            // check if position is in this section
            if (position >= currentPos && position <= (currentPos + sectionTotal - 1)) {

                if (section.hasHeader()) {
                    if (position == currentPos) {
                        // delegate the binding to the section header
                        if (payloads == null) {
                            getSectionForPosition(position).onBindHeaderViewHolder(holder);
                        } else {
                            getSectionForPosition(position).onBindHeaderViewHolder(holder, payloads);
                        }
                        return;
                    }
                }

                if (section.hasFooter()) {
                    if (position == currentPos + sectionTotal - 1) {
                        // delegate the binding to the section header
                        if (payloads == null) {
                            getSectionForPosition(position).onBindFooterViewHolder(holder);
                        } else {
                            getSectionForPosition(position).onBindFooterViewHolder(holder, payloads);
                        }
                        return;
                    }
                }

                // delegate the binding to the section content
                onBindContentViewHolder(getSectionForPosition(position), holder, position, payloads);
                return;
            }

            currentPos += sectionTotal;
        }

        throw new IndexOutOfBoundsException("Invalid position");
    }
Remove all sections from this adapter.
library/src/main/java/io/github/luizgrp/sectionedrecyclerviewadapter/SectionedRecyclerViewAdapter.java