protected function buildPageSettings($settings)
    {
        if (empty($settings)) {
            return $settings;
        }

        $output = [];
        foreach ($settings as $setting) {
            $output[$setting->setting_key] = $setting->setting_value;
        }

        return $output;
    }
protected function buildPageSettings($settings)
    {
        if (empty($settings)) {
            return $settings;
        }

        $output = [];
        foreach ($settings as $setting) {
            $output[$setting->setting_key] = $setting->setting_value;
        }

        return $output;
    }
protected function buildPageSettings ( $ settings ) { if ( empty ( $ settings ) ) { return $ settings ; } $ output = [ ] ; foreach ( $ settings as $ setting ) { $ output [ $ setting -> setting_key ] = $ setting -> setting_value ; } return $ output ; }
Build Page Settings

Takes array of page settings and changes keys to use setting->key as array keys
@param array  $settings Array of page settings
@return array
Build Page Settings