lib/symbolmatrix/serialization.rb in symbolmatrix-1.1.0 vs lib/symbolmatrix/serialization.rb in symbolmatrix-1.1.1
- old
+ new
@@ -1,8 +1,10 @@
class SymbolMatrix < Hash
class Serialization
def self.parse serialization
result = SymbolMatrix.new
+ return result if serialization.length == 0
+
if serialization.include? " "
serialization.split(" ").each do |command|
result = result.recursive_merge parse command
end
else