
Avoiding Conditionals, an example
I didn’t like the code I wrote for a particular feature. It was “notify users when someone comments in a discussion” with these requirements: * Notify discussion author, if not the comment creator * Notify users assigned to the parent model that is associated with the discussion, except: * the discussion author...