Created
April 30, 2014 23:26
-
-
Save j-mcnally/05a75adcfa6fd2ab1819 to your computer and use it in GitHub Desktop.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
irb(main):005:0> require 'ostruct' | |
=> true | |
irb(main):006:0> t = OpenStruct.new({:test => "yolo"}) | |
=> #<OpenStruct test="yolo"> | |
irb(main):007:0> t.to_hash | |
=> nil | |
irb(main):008:0> t.to_h | |
=> {:test=>"yolo"} | |
irb(main):009:0> |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment