Ruby's early returns can be harmful

Introduction I’ve been using Ruby for a some time now and I’ve noticed that early returns can be over used. I’ll review at one example with enums where I think some early returns can be harmful. Note: I am not saying early returns are bad, but in this specific example they can be harmful. Enums Ruby does not natively support enums, but they still do exist in business and other domains....

August 23, 2023 · 3 min · 473 words · benetis