X-Git-Url: https://git.mxchange.org/?a=blobdiff_plain;f=src%2FUtil%2FBasePath.php;h=4811239295a36e421e1c4c9f209f545e5ed36449;hb=911ed3d6ba98149ed6d400d554e7a0e10bd1c273;hp=06fa5246797028fb1bbee1dc75a5b7184db7726c;hpb=1de3960e267a8d298348fbca18cf1be1f6a20f7a;p=friendica.git diff --git a/src/Util/BasePath.php b/src/Util/BasePath.php index 06fa524679..4811239295 100644 --- a/src/Util/BasePath.php +++ b/src/Util/BasePath.php @@ -1,4 +1,23 @@ . + * + */ namespace Friendica\Util; @@ -24,7 +43,7 @@ class BasePath } /** - * @brief Returns the base filesystem path of the App + * Returns the base Friendica filesystem path without trailing slash * * It first checks for the internal variable, then for DOCUMENT_ROOT and * finally for PWD @@ -52,11 +71,11 @@ class BasePath throw new \Exception(sprintf('\'%s\' is not a valid basepath', $baseDir)); } - return $baseDir; + return rtrim($baseDir, '/'); } /** - * @brief Returns a normalized file path + * Returns a normalized file path * * This is a wrapper for the "realpath" function. * That function cannot detect the real path when some folders aren't readable.