Closed bandronic closed 7 years ago
This is one way to set a default value in an array key. The union array operator is similar to a merge, the right-hand side value will be appended. If the key exists in both operands, the left-hand side will be considered and the right-hand side will be ignored.
So, if the $options array coming as a parameter has the key 'atomic' set to a value(true or false), the union operation does nothing.
I does set the default atomic value to true, only if it was not set from the outside, in other words, the key is missing. This way we can omit an if statement
I think some test code slipped in AbstractDbMapper at line 257: