aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorJakub Senko <jakubsenko@gmail.com>2019-04-12 12:36:37 +0200
committerMarc Alexander <admin@m-a-styles.de>2019-09-30 20:25:54 +0200
commitd7c644a7923783f875ed7820d52388c8d9f765fb (patch)
treef8a0d644b0c7dfe138390464cbb5fde781625ca6
parent975fe1e153c35d7079d06655c43303b04a6502a7 (diff)
downloadforums-d7c644a7923783f875ed7820d52388c8d9f765fb.tar
forums-d7c644a7923783f875ed7820d52388c8d9f765fb.tar.gz
forums-d7c644a7923783f875ed7820d52388c8d9f765fb.tar.bz2
forums-d7c644a7923783f875ed7820d52388c8d9f765fb.tar.xz
forums-d7c644a7923783f875ed7820d52388c8d9f765fb.zip
[ticket/15257] Address validation issues
PHPBB3-15257
-rw-r--r--phpBB/includes/acp/acp_extensions.php7
-rw-r--r--tests/extension/ext/vendor5/foo/composer.json2
-rw-r--r--tests/extension/ext/vendor5/foo/ext.php2
3 files changed, 9 insertions, 2 deletions
diff --git a/phpBB/includes/acp/acp_extensions.php b/phpBB/includes/acp/acp_extensions.php
index da03b576bf..a9cbb8956b 100644
--- a/phpBB/includes/acp/acp_extensions.php
+++ b/phpBB/includes/acp/acp_extensions.php
@@ -724,6 +724,13 @@ class acp_extensions
}
}
+ /**
+ * Checks whether the extension can be enabled. Triggers error if not.
+ * Error message can be set by the extension.
+ *
+ * @param bool|array $enableable True if extension is enableable, array of reasons
+ * if not, false for generic reason.
+ */
protected function check_is_enableable($enableable)
{
if ($enableable !== true)
diff --git a/tests/extension/ext/vendor5/foo/composer.json b/tests/extension/ext/vendor5/foo/composer.json
index ddaee68dc4..0fa052e188 100644
--- a/tests/extension/ext/vendor5/foo/composer.json
+++ b/tests/extension/ext/vendor5/foo/composer.json
@@ -20,4 +20,4 @@
"phpbb/phpbb": "3.3.*@dev"
}
}
-} \ No newline at end of file
+}
diff --git a/tests/extension/ext/vendor5/foo/ext.php b/tests/extension/ext/vendor5/foo/ext.php
index 729e9d2a33..6bf03f001c 100644
--- a/tests/extension/ext/vendor5/foo/ext.php
+++ b/tests/extension/ext/vendor5/foo/ext.php
@@ -16,4 +16,4 @@ class ext extends \phpbb\extension\base
self::$enabled = true;
return self::$enabled;
}
-} \ No newline at end of file
+}