Skip to content

Commit

Permalink
fix #24780 change default isolation method in dol_clone
Browse files Browse the repository at this point in the history
This fixes serialization error when attempting to update a custom field value.
This change is made globally because the previous native = 0 default isolation
method is labeled as `deprecated` in the code and therefore shouldn't be used
anymore.

Signed-off-by: Alexis Thietard <alexis.thietard@rtone.fr>
  • Loading branch information
Al-thi committed Apr 18, 2024
1 parent c24fda1 commit 933362f
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion htdocs/core/lib/functions.lib.php
Original file line number Diff line number Diff line change
Expand Up @@ -1154,7 +1154,7 @@ function dol_buildpath($path, $type = 0, $returnemptyifnotfound = 0)
* @return object Clone object
* @see https://php.net/manual/language.oop5.cloning.php
*/
function dol_clone($object, $native = 0)
function dol_clone($object, $native = 2)
{
if ($native == 0) {
// deprecated method, use the method with native = 2 instead
Expand Down

0 comments on commit 933362f

Please sign in to comment.