Use mattr_accessor instead of cattr_accessor to support rails3

I use rails 3.2, when I try to start my app I always get undefined_method of 'cattr_accessor'
https://github.com/rails/rails/blob/master/activesupport/lib/active_support/core_ext/module/attribute_accessors.rb