Commit 1464b111 authored by Franco Fichtner's avatar Franco Fichtner

plugins: clearly annotate the reason why this is bad in general

parent 200bd3ee
......@@ -48,8 +48,16 @@ function plugins_scan()
foreach ($plugins as $plugin) {
$name = preg_replace('/' . preg_quote($path, '/') . '/', '', $plugin);
$name = preg_replace('/' . preg_quote($ext, '/') . '/', '', $name);
/* if the old file still exists upgrade went wrong */
if (file_exists($clash . $name . $ext)) {
/*
* Congratulations, you found the reason why your plugin doesn't
* work! It seems that you're using a name that is already taken
* by the base system. Please change the name of your plugin.
*
* A traceable call stack requires unique prefixes, which is what
* will prevent this from working. Do not remove this check
* without discussing the consequences with the authors.
*/
continue;
}
$ret[$name] = $plugin;
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment