Add umask when saving state to the file system to prevent permission denied error

This commit is contained in:
Ben Manu 2014-11-06 08:43:38 +13:00
parent cedb6e26ce
commit a50bab5445

View File

@ -299,7 +299,9 @@ class TestSessionEnvironment extends Object {
} else {
$content = json_encode($state);
}
$old = umask(0);
file_put_contents($this->getFilePath(), $content, LOCK_EX);
umask($old);
}
public function loadFromFile() {