Piwik\Plugins\CustomPiwikJs\TrackerUpdater::checkWillSucceed PHP Method

checkWillSucceed() public method

public checkWillSucceed ( )
    public function checkWillSucceed()
    {
        $this->fromFile->checkReadable();
        $this->toFile->checkWritable();
    }

Usage Example

Beispiel #1
0
 /**
  * Detects whether plugin trackers will be automatically added to piwik.js or not. If not, the plugin tracker files
  * need to be loaded manually.
  * @return bool
  */
 public function doesIncludePluginTrackersAutomatically()
 {
     Piwik::checkUserHasSomeAdminAccess();
     try {
         $updater = new TrackerUpdater();
         $updater->checkWillSucceed();
         return true;
     } catch (AccessDeniedException $e) {
         return false;
     } catch (\Exception $e) {
         return false;
     }
 }
All Usage Examples Of Piwik\Plugins\CustomPiwikJs\TrackerUpdater::checkWillSucceed