<?php
/**
 * Copyright: Shanghai NuLang Network Technology Co., Ltd.
 * Faith: Some things do not need others to understand.
 * Project: CoverCMS <Your world, your ambition>
 * License: http://www.svipplus.cn/license/
 * Author: The Rain° <rain@svipplus.cn>
 * File: SiteKit.php
 * Time: 10:58
 */

namespace app\common\toolKit;


class SiteKit
{
    public static function currentSiteId()
    {
        return 1;
    }

    public static function currentSiteInfo($siteId='')
    {
        $sites = cache('sites');
        if (empty(trim($siteId))){
            $siteId = self::currentSiteId();
        }
        if (array_key_exists(intval($siteId), $sites)) {
            return $sites[$siteId];
        }
        return $sites[1];
    }

}