From e4c2ae4ec103dbfcfd5378b7f78d5393c4498909 Mon Sep 17 00:00:00 2001 From: Eric Wong Date: Sat, 5 Dec 2015 05:44:12 +0000 Subject: tracklist: do not mutate @list when serializing This happens when "dtas-ctl state dump" is invoked manually; causing "dtas-tl cat" to break afterwards. Fixes: commit 7b065706d37df9e54c8b3299ce696545c6159fa4 ("tracklist: use lower number unique track IDs") --- lib/dtas/tracklist.rb | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/lib/dtas/tracklist.rb b/lib/dtas/tracklist.rb index 696026a..1750f26 100644 --- a/lib/dtas/tracklist.rb +++ b/lib/dtas/tracklist.rb @@ -30,7 +30,7 @@ class DTAS::Tracklist # :nodoc: def to_hsh h = ivars_to_hash(SIVS) h.delete_if { |k,v| TL_DEFAULTS[k] == v } - list = h['list'] and list.map!(&:to_path) + list = h['list'] and h['list'] = list.map(&:to_path) h end -- cgit v1.2.3-24-ge0c7