lysdexic@programming.dev to Programming@programming.devEnglish · 4 months agoGood Refactoring vs Bad Refactoringwww.builder.ioexternal-linkmessage-square4fedilinkarrow-up172arrow-down14
arrow-up168arrow-down1external-linkGood Refactoring vs Bad Refactoringwww.builder.iolysdexic@programming.dev to Programming@programming.devEnglish · 4 months agomessage-square4fedilink
minus-squareEager Eagle@lemmy.worldlinkfedilinkEnglisharrow-up11·4 months agoTotally agree. The hardcoded isAdult: true repeated in all #2 examples seems like a bug waiting to happen; that should be a property dynamically computed from the age during access time, not a static thing.
Totally agree. The hardcoded
isAdult: true
repeated in all #2 examples seems like a bug waiting to happen; that should be a property dynamically computed from the age during access time, not a static thing.