Skip to content

Commit

Permalink
Merge pull request Hanson#33 from HanSon/dev
Browse files Browse the repository at this point in the history
path不存在时message.json存储失败
  • Loading branch information
Hanson authored Feb 1, 2017
2 parents 9c20350 + 211c35d commit b8c48e0
Showing 1 changed file with 7 additions and 1 deletion.
8 changes: 7 additions & 1 deletion src/Support/System.php
Original file line number Diff line number Diff line change
Expand Up @@ -24,6 +24,12 @@ public static function isWin()

public static function getPath()
{
return server()->config['tmp'] . '/' . myself()->alias . '/';
$path = server()->config['tmp'] . '/' . myself()->alias . '/';

if(!is_dir(realpath($path))){
mkdir($path, 0700, true);
}

return $path;
}
}

0 comments on commit b8c48e0

Please sign in to comment.