Skip to content

Commit

Permalink
Merge pull request #12 from abkarim/0.2.5
Browse files Browse the repository at this point in the history
0.2.5
  • Loading branch information
abkarim authored Nov 18, 2023
2 parents 4349385 + d2174fa commit 68c644d
Show file tree
Hide file tree
Showing 11 changed files with 2,935 additions and 89 deletions.
11 changes: 11 additions & 0 deletions includes/classes/settings/Color.php
Original file line number Diff line number Diff line change
@@ -1,4 +1,5 @@
<?php

namespace Xynity_Blocks;

/**
Expand Down Expand Up @@ -54,6 +55,16 @@ public static function update_color_options($data): bool
$updated_data["settings"]["color"]["palette"] = $palette;
}

/**
* Replace current duotone with old duotone
*
* @since 0.2.5
*/
$duotone = Util::get_value_if_present_in_array($data, "duotone", null);
if (!is_null($palette)) {
$updated_data["settings"]["color"]["duotone"] = $duotone;
}

return self::write_into_theme_json($updated_data);
}
}
Loading

0 comments on commit 68c644d

Please sign in to comment.