mirror of
https://github.com/phpbb/phpbb.git
synced 2025-06-28 14:18:52 +00:00
[ticket/11515] Inverted Logic
Inverted the logic to raise exception inside if. PHPBB3-11515
This commit is contained in:
parent
f1c2f7baae
commit
dfcce400a4
1 changed files with 3 additions and 3 deletions
|
@ -101,11 +101,11 @@ class flock
|
|||
|
||||
if ($this->lock_fp)
|
||||
{
|
||||
if (@flock($this->lock_fp, LOCK_EX))
|
||||
if (!@flock($this->lock_fp, LOCK_EX))
|
||||
{
|
||||
return (bool) $this->lock_fp;
|
||||
throw new \phpbb\exception\http_exception(500, 'Failure while aqcuiring locks.');
|
||||
}
|
||||
throw new \phpbb\exception\http_exception(500, 'Failure while aqcuiring locks.');
|
||||
return (bool) $this->lock_fp;
|
||||
}
|
||||
|
||||
return (bool) $this->lock_fp;
|
||||
|
|
Loading…
Add table
Reference in a new issue