Skip to content

umask #178

@bacinsky

Description

@bacinsky

Hi, the umask is used to set right file permissions of cached files in the FilePathCache

but I'm using the Assetc's FilesystemCache also but there is no umask fix, so I wonder if it will be good to provide that fix within the AssetManager or I have to handle it by myself. I think it's kind of a common issue, but maybe there is a better solution I dont' know.

class FilesystemCache extends \Assetic\Cache\FilesystemCache
{
    /**
     * {@inheritdoc}
     */
    public function set($key, $value)
    {
        $umask = umask(0);
        parent::set($key, $value);
        umask($umask);
    }
}

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions