diff options
author | Vincent Peugnet <33429034+vincent-peugnet@users.noreply.github.com> | 2020-03-25 19:55:25 +0100 |
---|---|---|
committer | GitHub <noreply@github.com> | 2020-03-25 19:55:25 +0100 |
commit | a17b7fc6aa87341c51e68baf3f217f709eb817d7 (patch) | |
tree | ba6958ba93e76d2464ad9ae068b9bd56400d5294 /app/class/Config.php | |
parent | fa92ec6b40676677595047b71b3c2fafb1bf89ea (diff) | |
parent | d17713051ca2fef29de8025fe876d417838cea7f (diff) | |
download | wcms-a17b7fc6aa87341c51e68baf3f217f709eb817d7.tar.gz wcms-a17b7fc6aa87341c51e68baf3f217f709eb817d7.zip |
Merge pull request #72 from n-peugnet/implement-cytoscape.js
Implement cytoscape.js
Diffstat (limited to 'app/class/Config.php')
-rw-r--r-- | app/class/Config.php | 13 |
1 files changed, 11 insertions, 2 deletions
diff --git a/app/class/Config.php b/app/class/Config.php index fa9082f..2cfdcd3 100644 --- a/app/class/Config.php +++ b/app/class/Config.php @@ -3,6 +3,8 @@ namespace Wcms; +use Http\Client\Common\Plugin\RetryPlugin; + abstract class Config { protected static $pagetable = 'mystore'; @@ -129,9 +131,16 @@ abstract class Config return self::$fontsize; } - public static function basepath() + /** + * @param bool $trailingslash If not empty basepath, add a trailing slash after the basepath + */ + public static function basepath(bool $trailingslash = false) : string { - return self::$basepath; + if($trailingslash && !empty(self::$basepath)) { + return self::$basepath . '/'; + } else { + return self::$basepath; + } } public static function route404() |