We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent 4fe88ce commit c477bbcCopy full SHA for c477bbc
src/Sys.php
@@ -60,6 +60,11 @@ public static function isRoot(): bool
60
*/
61
public static function getHome()
62
{
63
+ $userInfo = posix_getpwuid(posix_geteuid());
64
+ if (isset($userInfo['dir'])) {
65
+ return $userInfo['dir'];
66
+ }
67
+
68
if (Arr::key('HOMEDRIVE', $_SERVER)) {
69
return $_SERVER['HOMEDRIVE'] . $_SERVER['HOMEPATH'];
70
}
0 commit comments