summaryrefslogtreecommitdiff
path: root/classes/pluginhost.php
diff options
context:
space:
mode:
authorAndrew Dolgov <[email protected]>2021-03-03 23:38:52 +0300
committerAndrew Dolgov <[email protected]>2021-03-03 23:38:52 +0300
commit8256ab5dd901904dfa8f78ebc3f3ed08a969226d (patch)
treef051c8bd3e61e7f7451042e130d9352d7fed2cbb /classes/pluginhost.php
parent0cb719a40447e30011142714d5e5ce55c051a118 (diff)
wip: initial for db_migrations
Diffstat (limited to 'classes/pluginhost.php')
-rwxr-xr-xclasses/pluginhost.php7
1 files changed, 6 insertions, 1 deletions
diff --git a/classes/pluginhost.php b/classes/pluginhost.php
index 746b780e4..366e2b2d3 100755
--- a/classes/pluginhost.php
+++ b/classes/pluginhost.php
@@ -624,9 +624,14 @@ class PluginHost {
}
}
- function is_local(Plugin $plugin) {
+ function get_plugin_dir(Plugin $plugin) {
$ref = new ReflectionClass(get_class($plugin));
+ return dirname($ref->getFileName());
+ }
+ // TODO: use get_plugin_dir()
+ function is_local(Plugin $plugin) {
+ $ref = new ReflectionClass(get_class($plugin));
return basename(dirname(dirname($ref->getFileName()))) == "plugins.local";
}
}