Piwik\Plugins\SitesManager\API::getSitesWithAtLeastViewAccess PHP Method

getSitesWithAtLeastViewAccess() public method

For the superUser it returns all the websites in the database.
public getSitesWithAtLeastViewAccess ( boolean | integer $limit = false, boolean $_restrictSitesToLogin = false ) : array
$limit boolean | integer Specify max number of sites to return
$_restrictSitesToLogin boolean Hack necessary when running scheduled tasks, where "Super User" is forced, but sometimes not desired, see #3017
return array array for each site, an array of information (idsite, name, main_url, etc.)
    public function getSitesWithAtLeastViewAccess($limit = false, $_restrictSitesToLogin = false)
    {
        $sitesId = $this->getSitesIdWithAtLeastViewAccess($_restrictSitesToLogin);
        return $this->getSitesFromIds($sitesId, $limit);
    }