Skip to content

Commit 684406f

Browse files
author
Gerard Hickey
committed
Fixed mem facter module when memory size is in lshw output
1 parent b5f8a55 commit 684406f

File tree

1 file changed

+5
-5
lines changed

1 file changed

+5
-5
lines changed

hanlon_microkernel/facter/hnl_mk_mem.rb

Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -193,11 +193,11 @@ def pretty_memory_size(bytes)
193193
end
194194
end
195195
end
196-
197-
# finally... create the fact
198-
Facter.add("mk_hw_mem_size") do
199-
setcode { pretty_memory_size(bytes) }
200-
end
196+
val = pretty_memory_size(bytes)
197+
end
198+
# finally... create the fact
199+
Facter.add("mk_hw_mem_size") do
200+
setcode { val }
201201
end
202202

203203
# slot info is going to need a bunch of work

0 commit comments

Comments
 (0)