mirror of
https://github.com/emilybache/GildedRose-Refactoring-Kata.git
synced 2026-02-13 21:52:19 +00:00
chore: remove un-needed if condition
This commit is contained in:
parent
6faeed5b7d
commit
80a2e70216
@ -25,11 +25,7 @@ final class GildedRose
|
|||||||
|
|
||||||
|
|
||||||
if ($item->name != 'Aged Brie' and $item->name != 'Backstage passes to a TAFKAL80ETC concert') {
|
if ($item->name != 'Aged Brie' and $item->name != 'Backstage passes to a TAFKAL80ETC concert') {
|
||||||
if ($item->quality > 0) {
|
$item->quality = max(0, --$item->quality);
|
||||||
if ($item->name != 'Sulfuras, Hand of Ragnaros') {
|
|
||||||
$item->quality = $item->quality - 1;
|
|
||||||
}
|
|
||||||
}
|
|
||||||
} else {
|
} else {
|
||||||
if ($item->quality < 50) {
|
if ($item->quality < 50) {
|
||||||
$item->quality = $item->quality + 1;
|
$item->quality = $item->quality + 1;
|
||||||
|
|||||||
Loading…
Reference in New Issue
Block a user