Options of select field in a custom divi module ignore sorting

Turns out, Divi cannot handle associative arrays, in my case with post id as key and post title as value. Using an indexed array solves the problem. Unfortunately, this is not mentioned anywhere in the documentation.

Thus I changed the code in the get_post_options() function from

foreach ($posts as $post) {
        $options[$post->ID] = $post->post_title;
    }

to

$index = 1;
    foreach ($posts as $post) {
        $options[$index] = $post->post_title;
        $index++;
    }

Why this is the case, I can’t answer.

deneme bonusu veren sitelerbahis siteleripulibet girişdeneme bonusutürkçe altyazılı pornocanlı bahis casinocanlı bahis casino siteleriOnwin Güncel Girişholiganbetholiganbet girişholiganbet güncel giriş