aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--CHANGELOG.md8
-rw-r--r--lib/Config.rakumod2
2 files changed, 9 insertions, 1 deletions
diff --git a/CHANGELOG.md b/CHANGELOG.md
index 9874325..dc7ff5c 100644
--- a/CHANGELOG.md
+++ b/CHANGELOG.md
@@ -5,6 +5,14 @@ The format is based on [Keep a Changelog](http://keepachangelog.com/en/1.0.0/)
and this project adheres to [Semantic
Versioning](http://semver.org/spec/v2.0.0.html).
+## [Unreleased]
+
+### Changed
+
+- `.read` now uses `%!data.clone`, instead of `%!data`. This should fix an
+ issue where the `Hash` used is shared between the objects, resulting in
+ hard-to-debug errors.
+
## [3.0.0] - 2020-07-12
`Config` has been rebuilt from the ground up. This is a relatively old
diff --git a/lib/Config.rakumod b/lib/Config.rakumod
index f85774a..2d33b71 100644
--- a/lib/Config.rakumod
+++ b/lib/Config.rakumod
@@ -149,7 +149,7 @@ multi method read (
Config.new(
%!template,
:$!name,
- data => merge-hash(%!data, %data),
+ data => merge-hash(%!data.clone, %data),
:!read-from-env,
:!read-from-xdg,
)