Add the ability to set the maxDepth in Hash::flatten

Allows you to set the max depth the Hash::flatten function will "recurse" down into the array.  I'm using this for the utility of it, but it would also add a limit to prevent excessive iterations down into the array.

I've set the default maxDepth to 20.  Technically, this could be breaking.  Realistically, I cannot see a practical reason to flatten an array with a depth larger than 20.