Skip to content

Commit 0942470

Browse files
RomainLvrRom1-B
andauthored
Fix (Uninstall) - Restore mini-dashboard delete function (#3621)
* Fix (Uninstall) - Restore mini-dashboard delete function * Fix phpstan * Fix phpstan * Update src/Install.php Co-authored-by: Romain B. <[email protected]> * Delete phpunit.xml to avoid CI errors --------- Co-authored-by: Romain B. <[email protected]>
1 parent 022e933 commit 0942470

File tree

2 files changed

+9
-8
lines changed

2 files changed

+9
-8
lines changed

phpunit.xml

Lines changed: 0 additions & 8 deletions
This file was deleted.

src/Install.php

Lines changed: 9 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -491,6 +491,14 @@ protected function deleteTables() {
491491
$displayPreference->deleteByCriteria(['itemtype' => 'PluginFormcreatorIssue']);
492492
}
493493

494+
protected function deleteMiniDashboard(): bool {
495+
$dashboard = new Dashboard();
496+
497+
return $dashboard->deleteByCriteria([
498+
'key' => 'plugin_formcreator_issue_counters'
499+
]);
500+
}
501+
494502
/**
495503
* http://stackoverflow.com/questions/834303/startswith-and-endswith-functions-in-php
496504
* @param string $haystack
@@ -508,6 +516,7 @@ public function uninstall() {
508516
$this->deleteTicketRelation();
509517
$this->deleteTables();
510518
$this->deleteNotifications();
519+
$this->deleteMiniDashboard();
511520

512521
$config = new Config();
513522
$config->deleteByCriteria(['context' => 'formcreator']);

0 commit comments

Comments
 (0)