Code
Explorer
You are a developer and looking for Shopware projects?
Apply Now!
fixFilePermission example
return
$errors
;
}
/** @var DirectoryIterator $fileInfo */
foreach
(
new
DirectoryIterator
(
$directory
)
as
$fileInfo
)
{
if
(
$fileInfo
->
isDot
(
)
)
{
continue
;
}
if
(
$fileInfo
->
isFile
(
)
)
{
if
(
$fixPermission
&& !
$fileInfo
->
isWritable
(
)
)
{
$this
->
fixFilePermission
(
$fileInfo
)
;
}
if
(
!
$fileInfo
->
isWritable
(
)
)
{
$errors
[
]
=
$fileInfo
->
getPathname
(
)
;
}
continue
;
}
// skip VCS dirs
if
(
\
in_array
(
$fileInfo
->
getBasename
(
)
,
$this
->VCSDirs, true
)
)
{