Ad
  • Custom User Avatar

    Seems like you're following bad practices if you're mutating an object passed to your function when that is not the function's purpose.
    The only time you should mutate an argument is when that is the explicit goal of the function.

    Imagine calling the built-in min() function on a list, only to find that the function has removed all the items in the list except the minimum.