Remove redundant cast to bool

This commit is contained in:
Grant Millar 2021-09-20 17:23:30 +01:00 committed by Robin Appelman
commit 6066f7ed66

View file

@ -99,7 +99,7 @@ class NativeFileInfo implements IFileInfo {
public function isDirectory(): bool { public function isDirectory(): bool {
$mode = $this->getMode(); $mode = $this->getMode();
if ($mode > 0x1000) { if ($mode > 0x1000) {
return (bool)($mode & 0x4000 && !($mode & 0x8000)); // 0x4000: unix directory flag shares bits with 0xC000: socket return ($mode & 0x4000 && !($mode & 0x8000)); // 0x4000: unix directory flag shares bits with 0xC000: socket
} else { } else {
return (bool)($mode & IFileInfo::MODE_DIRECTORY); return (bool)($mode & IFileInfo::MODE_DIRECTORY);
} }