update Piwik to version 2.16 (fixes #91)

This commit is contained in:
oliver 2016-04-10 18:55:57 +02:00
commit 47263617c5
5833 changed files with 418860 additions and 226988 deletions

View file

@ -1,6 +1,6 @@
<?php
/**
* Piwik - Open source web analytics
* Piwik - free/libre analytics platform
*
* @link http://piwik.org
* @license http://www.gnu.org/licenses/gpl-3.0.html GPL v3 or later
@ -11,6 +11,7 @@ namespace Piwik\Plugins\Overlay;
use Exception;
use Piwik\Access;
use Piwik\Config;
use Piwik\Container\StaticContainer;
use Piwik\DataTable;
use Piwik\Piwik;
use Piwik\Plugins\SitesManager\API as APISitesManager;
@ -105,26 +106,26 @@ class API extends \Piwik\Plugin\API
{
/**
* Triggered immediately before the user is authenticated.
*
*
* This event can be used by plugins that provide their own authentication mechanism
* to make that mechanism available. Subscribers should set the `'auth'` object in
* the {@link Piwik\Registry} to an object that implements the {@link Piwik\Auth} interface.
*
* to make that mechanism available. Subscribers should set the `'Piwik\Auth'` object in
* the container to an object that implements the {@link Piwik\Auth} interface.
*
* **Example**
*
* use Piwik\Registry;
*
*
* use Piwik\Container\StaticContainer;
*
* public function initAuthenticationObject($activateCookieAuth)
* {
* Registry::set('auth', new LDAPAuth($activateCookieAuth));
* StaticContainer::getContainer()->set('Piwik\Auth', new LDAPAuth($activateCookieAuth));
* }
*
*
* @param bool $activateCookieAuth Whether authentication based on `$_COOKIE` values should
* be allowed.
*/
Piwik::postEvent('Request.initAuthenticationObject', array($activateCookieAuth = true));
$auth = \Piwik\Registry::get('auth');
$auth = StaticContainer::get('Piwik\Auth');
$success = Access::getInstance()->reloadAccess($auth);
if (!$success) {