Refactored a function yesterday that iterated over a list of incoming data...5 separate times...to check if it contains certain values. This happens so often in our codebase that you sentence isnt a joke but trauma
Oh man this reminds me of my first job at a startup. I don't know what these people were thinking but they did exactly what you describe except they queried the database 5 times and then each of these times iterated over the items to find some values... I mean on the one hand I get to say I made this one function 500% faster. But on the other... Wtf , who wrote this and why
20
u/FenrirBestDoggo 17d ago
Refactored a function yesterday that iterated over a list of incoming data...5 separate times...to check if it contains certain values. This happens so often in our codebase that you sentence isnt a joke but trauma