mirror of
https://github.com/Findus23/plugin-ProfileAvatar.git
synced 2024-09-19 15:23:45 +02:00
Matomo 5 compatibility
This commit is contained in:
parent
1d16146ce1
commit
49099ef3e6
3 changed files with 12 additions and 4 deletions
|
@ -1,5 +1,13 @@
|
|||
## Changelog
|
||||
|
||||
### 0.2.0
|
||||
|
||||
Matomo 5 compatibility
|
||||
|
||||
### 0.1.6
|
||||
|
||||
add French, Japanese, Italian, Portuguese, Portuguese (Brazil) and Ukrainian translations
|
||||
|
||||
### 0.1.5
|
||||
|
||||
add German, Greek and Turkish translations
|
||||
|
|
|
@ -2,7 +2,6 @@
|
|||
|
||||
namespace Piwik\Plugins\ProfileAvatar;
|
||||
|
||||
use Piwik\Common;
|
||||
use Piwik\Piwik;
|
||||
|
||||
class Controller extends \Piwik\Plugin\Controller
|
||||
|
@ -13,7 +12,8 @@ class Controller extends \Piwik\Plugin\Controller
|
|||
public function getProfileAvatar(): void
|
||||
{
|
||||
Piwik::checkUserHasSomeViewAccess();
|
||||
$hash = Common::getRequestVar('hash', "", 'string');
|
||||
$request = \Piwik\Request::fromRequest();
|
||||
$hash = $request->getStringParameter('hash', "");
|
||||
$settings = new UserSettings();
|
||||
$chosenGenerator = $settings->avatarType->getValue();
|
||||
$generator = GeneratorCollection::getGeneratorClasses($chosenGenerator, $hash);
|
||||
|
|
|
@ -1,10 +1,10 @@
|
|||
{
|
||||
"name": "ProfileAvatar",
|
||||
"description": "Show a random avatar on the Visitor Profile",
|
||||
"version": "0.1.5",
|
||||
"version": "0.2.0",
|
||||
"theme": false,
|
||||
"require": {
|
||||
"matomo": ">=3.13.0,<5.0.0-b1"
|
||||
"matomo": ">=5.0.0-b1,<6.0.0-b1"
|
||||
},
|
||||
"authors": [
|
||||
{
|
||||
|
|
Loading…
Reference in a new issue