private function buildGravatarConfig(ThemeModel $theme, array $config): array
    {
        $file = FilesModel::findByPk($theme->bs_gravatar_default);

        if ($file) {
            $config['gravatar']['default'] = Environment::get('base') . $file->path;
        }

        if ($theme->bs_gravatar_size) {
            $config['gravatar']['size'] = (int) $theme->bs_gravatar_size;
        }

        return $config;
    }