public function sortPages($pages)
    {
        usort($pages['_items'], function ($a, $b) {
            //need to convert them to lowercase strings for equal comparison
            return strcmp(strtolower($a["name"]), strtolower($b["name"]));
        });

        return $pages;
    }