mirror of
https://github.com/emilybache/GildedRose-Refactoring-Kata.git
synced 2026-02-16 06:51:27 +00:00
Simply expressions
This commit is contained in:
parent
2cd5a72201
commit
87617c7f25
@ -58,18 +58,18 @@ export class GildedRose {
|
||||
|
||||
if (item.name == 'Aged Brie') {
|
||||
if (item.quality < 50) {
|
||||
item.quality = item.quality + 1;
|
||||
item.quality++
|
||||
}
|
||||
return
|
||||
}
|
||||
|
||||
if (item.name == 'Backstage passes to a TAFKAL80ETC concert') {
|
||||
item.quality = item.quality - item.quality;
|
||||
item.quality = 0
|
||||
return
|
||||
}
|
||||
|
||||
if (item.quality > 0) {
|
||||
item.quality = item.quality - 1;
|
||||
item.quality--
|
||||
return
|
||||
}
|
||||
}
|
||||
|
||||
Loading…
Reference in New Issue
Block a user