Aijan@programming.dev to Programming@programming.dev · 6 hours agoSelf-documenting Codelackofimagination.orgexternal-linkmessage-square33fedilinkarrow-up146arrow-down17
arrow-up139arrow-down1external-linkSelf-documenting Codelackofimagination.orgAijan@programming.dev to Programming@programming.dev · 6 hours agomessage-square33fedilink
minus-squaretraches@sh.itjust.workslinkfedilinkEnglisharrow-up33·6 hours agoAgreed. OP was doing well until they replaced the if statements with ‚function call || throw error’. That’s still an if statement, but obfuscated.
minus-squareBrianTheeBiscuiteer@lemmy.worldlinkfedilinkarrow-up2·3 hours agoDon’t mind the || but I do agree if you’re validating an input you’d best find all issues at once instead of “first rule wins”.
Agreed. OP was doing well until they replaced the if statements with ‚function call || throw error’. That’s still an if statement, but obfuscated.
Don’t mind the
||
but I do agree if you’re validating an input you’d best find all issues at once instead of “first rule wins”.