← Previous · All Episodes · Next →
Navigating the Absurdities of Code: Sebastian's Struggle with Redundant Functions Episode

Navigating the Absurdities of Code: Sebastian's Struggle with Redundant Functions

· 01:10

|

Welcome to The Daily WTF podcast. Today, we’re diving into the absurdities of software development through the story of Sebastian, who’s wrangling a massive framework that he claims could be slashed by 50%. Why? Because it’s filled with reinvented functions that already exist in .NET, particularly with LINQ.

For instance, consider the function FindFirst, which is supposed to find the first logging rule based on a given condition. But here’s the catch: it doesn’t actually filter anything. It just returns the first item in a collection, ignoring the predicate entirely. As the article notes, “if the loop doesn't contain any elements, we return null.”

Sebastian reflects, “I don't know why this exists, but I especially dislike that it's so misleading.” This brings us to the crux of the issue: why add unnecessary complexity when there are built-in solutions ready to go? It’s a clear reminder that sometimes, the first step to efficiency is simply cutting out the needless extra code. Tune in next time for more tales from the world of coding gone wrong!
Link to Article


Subscribe

Listen to jawbreaker.io using one of many popular podcasting apps or directories.

Apple Podcasts Spotify Overcast Pocket Casts Amazon Music
← Previous · All Episodes · Next →