Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
3 changes: 3 additions & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
@@ -1,5 +1,8 @@
# Changelog ##

## 2.1.3 - 21 Sept 2023
* Compat to PHP 8.1 change singleton functions declarations

## 2.1.2 - 19 May 2023
* Fix final function must have public visibility.

Expand Down
6 changes: 3 additions & 3 deletions bea-media-analytics.php
Original file line number Diff line number Diff line change
@@ -1,14 +1,14 @@
<?php
/*
Plugin Name: BEA - Media Analytics
Version: 2.1.2
Version: 2.1.3
Plugin URI: https://github.com/BeAPI/bea-media-analytics
Description: Find where and how media are used across your site.
Author: Be API Technical team
Author URI: https://beapi.fr
Domain Path: languages
Text Domain: bea-media-analytics
Contributors: Maxime Culea, Amaury Balmer
Contributors: Maxime Culea, Amaury Balmer, Ingrid Azéma, François de Cambourg

----

Expand All @@ -35,7 +35,7 @@
}

// Plugin constants
define( 'BEA_MEDIA_ANALYTICS_VERSION', '2.1.2' );
define( 'BEA_MEDIA_ANALYTICS_VERSION', '2.1.3' );
define( 'BEA_MEDIA_ANALYTICS_MIN_PHP_VERSION', '5.6' );

// Plugin URL and PATH
Expand Down
14 changes: 8 additions & 6 deletions classes/singleton.php
Original file line number Diff line number Diff line change
Expand Up @@ -46,16 +46,18 @@ protected function init() {}
/**
* prevent the instance from being cloned
*
* @return void
* @throws \LogicException
*/
final public function __clone() {
}
final public function __clone() {
throw new \LogicException( 'A singleton must not be unserialized!' );
}

/**
* prevent from being unserialized
*
* @return void
* @throws \LogicException
*/
final public function __wakeup() {
}
final public function __wakeup() {
Comment thread
f2cmbeapi marked this conversation as resolved.
throw new \LogicException( 'A singleton must not be unserialized!' );
}
}