Skip to content

Commit 5b8e282

Browse files
Merge pull request #27 from matomo-org/PG-5045-fix-regression
Fixes exception when request parameter not defined
2 parents 5696d31 + 0748551 commit 5b8e282

3 files changed

Lines changed: 7 additions & 4 deletions

File tree

CHANGELOG.md

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,8 @@
11
## Changelog
22

3+
5.0.5 - 2026-03-30
4+
- Fixed exception when module, action and idsite is not defined when setting js variables
5+
36
5.0.4 - 2026-03-30
47
- Added code to add notification if using deprecated Microsoft Teams webhook URL and also send an email via migration
58

MicrosoftTeams.php

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -78,11 +78,11 @@ public function getJsFiles(&$jsFiles)
7878
public function addJsGlobalVariables(&$out)
7979
{
8080
$request = \Piwik\Request::fromRequest();
81-
$module = $request->getParameter('module');
82-
$action = $request->getParameter('action');
81+
$module = $request->getParameter('module', '');
82+
$action = $request->getParameter('action', '');
8383
$shouldShowNotification = false;
8484
$login = Piwik::getCurrentUserLogin();
85-
$idSite = $request->getParameter('idSite');
85+
$idSite = $request->getParameter('idSite', '');
8686
if ($module === 'ScheduledReports' && $action === 'index' && $idSite) {
8787
$table = Common::prefixTable('report');
8888
$sql = "SELECT count(type) FROM `$table` WHERE type = ? AND idsite = ? AND deleted = 0 AND login = ?"

plugin.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
{
22
"name": "MicrosoftTeams",
33
"description": "Send Matomo reports and alerts to Microsoft Team channels, keeping your team informed and ready to act in real time.",
4-
"version": "5.0.4",
4+
"version": "5.0.5",
55
"theme": false,
66
"require": {
77
"matomo": ">=5.7.0-alpha,<6.0.0-b1"

0 commit comments

Comments
 (0)