Fixed incorrect usage of cattr_accessor
Changed to ruby 1.9 style hashes