only use attr_accessible if it's supported
removed duplicate dependency