From 088524e32649647561ff2fa54eb4c7bd8e269842 Mon Sep 17 00:00:00 2001 From: Jared Hancock <jared@osticket.com> Date: Wed, 10 Dec 2014 16:44:17 -0600 Subject: [PATCH] oops: Don't crash uninstalling a plugin with no config --- include/class.plugin.php | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/include/class.plugin.php b/include/class.plugin.php index a6b653697..db496e33a 100644 --- a/include/class.plugin.php +++ b/include/class.plugin.php @@ -402,7 +402,9 @@ abstract class Plugin { if (!db_query($sql) || !db_affected_rows()) return false; - $this->getConfig()->purge(); + if ($config = $this->getConfig()) + $config->purge(); + return true; } -- GitLab