Code Duplication    Length = 3-3 lines in 2 locations

src/CImage/CImage.php 2 locations

@@ 1796-1798 (lines=3) @@
1793
                $cropX = 0;
1794
                $cropY = 0;
1795
1796
                if ($this->newWidth > $this->width) {
1797
                    $posX = round(($this->newWidth - $this->width) / 2);
1798
                }
1799
                if ($this->newWidth < $this->width) {
1800
                    $cropX = round(($this->width/2) - ($this->newWidth/2));
1801
                }
@@ 1799-1801 (lines=3) @@
1796
                if ($this->newWidth > $this->width) {
1797
                    $posX = round(($this->newWidth - $this->width) / 2);
1798
                }
1799
                if ($this->newWidth < $this->width) {
1800
                    $cropX = round(($this->width/2) - ($this->newWidth/2));
1801
                }
1802
1803
                if ($this->newHeight > $this->height) {
1804
                    $posY = round(($this->newHeight - $this->height) / 2);