Thanks to visit codestin.com
Credit goes to github.com

Skip to content
This repository was archived by the owner on Jan 31, 2020. It is now read-only.

Commit 07e1aab

Browse files
committed
Conflicts: library/Zend/File/Transfer/Adapter/AbstractAdapter.php library/Zend/Validator/File/ExcludeExtension.php library/Zend/Validator/File/ImageSize.php library/Zend/Validator/File/NotExists.php

2 files changed

Lines changed: 4 additions & 4 deletions

File tree

src/File/ExcludeExtension.php

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -66,7 +66,7 @@ public function isValid($value)
6666
$extension = substr($filename, strrpos($filename, '.') + 1);
6767
$extensions = $this->getExtension();
6868

69-
if ($this->getCase() and (!in_array($extension, $extensions))) {
69+
if ($this->getCase() && (!in_array($extension, $extensions))) {
7070
return true;
7171
} elseif (!$this->getCase()) {
7272
foreach ($extensions as $ext) {

src/File/ImageSize.php

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -351,7 +351,7 @@ public function isValid($value)
351351
$size = getimagesize($file);
352352
ErrorHandler::stop();
353353

354-
if (empty($size) or ($size[0] === 0) or ($size[1] === 0)) {
354+
if (empty($size) || ($size[0] === 0) || ($size[1] === 0)) {
355355
$this->error(self::NOT_DETECTED);
356356
return false;
357357
}
@@ -362,15 +362,15 @@ public function isValid($value)
362362
$this->error(self::WIDTH_TOO_SMALL);
363363
}
364364

365-
if (($this->getMaxWidth() !== null) and ($this->getMaxWidth() < $this->width)) {
365+
if (($this->getMaxWidth() !== null) && ($this->getMaxWidth() < $this->width)) {
366366
$this->error(self::WIDTH_TOO_BIG);
367367
}
368368

369369
if ($this->height < $this->getMinHeight()) {
370370
$this->error(self::HEIGHT_TOO_SMALL);
371371
}
372372

373-
if (($this->getMaxHeight() !== null) and ($this->getMaxHeight() < $this->height)) {
373+
if (($this->getMaxHeight() !== null) && ($this->getMaxHeight() < $this->height)) {
374374
$this->error(self::HEIGHT_TOO_BIG);
375375
}
376376

0 commit comments

Comments
 (0)