# Question about some changes from Ruby 1.8.6 to Ruby 1.9

**URL:** <https://www.ruby-forum.com/t/question-about-some-changes-from-ruby-1-8-6-to-ruby-1-9/181832>\
**Category:** Ruby\
**Created:** [January 18, 2010, 11:14pm UTC](https://www.ruby-forum.com/t/question-about-some-changes-from-ruby-1-8-6-to-ruby-1-9/181832 "2010-01-18T23:14:48Z")\
**Posts on this page:** 2\
**Page:** 1

<div class="post-metadata">

**Author:** ![elricstorm](https://www.ruby-forum.com/letter_avatar_proxy/v4/letter/e/da6949/32.png) [@elricstorm](https://www.ruby-forum.com/u/elricstorm)\
**Post date:** [January 18, 2010, 11:14pm UTC](https://www.ruby-forum.com/t/question-about-some-changes-from-ruby-1-8-6-to-ruby-1-9/181832/1 "2010-01-18T23:14:48Z")

</div>

So, the bulk of my issues thus far have been pretty simple and I’ve  
isolated and ported over a very lengthy app from 1.8.6 to 1.9.1.

The biggest issues I saw were things like scopes:

Before:

named\_scope :private\_pages,  
:conditions =\> ‘pages.parent\_id IS NULL and pages.subpage\_id IS NULL’,  
:order =\> ‘pages.position’,  
:include =\> {:subpages, :subofsubs}

After:

named\_scope :private\_pages,  
:conditions =\> ‘pages.parent\_id IS NULL and pages.subpage\_id IS NULL’,  
:order =\> ‘pages.position’,  
:include =\> [:subpages, :subofsubs]

… and also the use of string.to\_a in much of my code

Before: new\_array += val.strip).to\_a  
After: new\_array += Array(val.strip)

So, where can I find a solid page or two on a complete list rundown of  
all changes from 1.8.6/1.8.7 to 1.9.x? I would like to keep a reference  
somewhere handy.

---

<div class="post-metadata">

**Author:** ![elricstorm](https://www.ruby-forum.com/letter_avatar_proxy/v4/letter/e/da6949/32.png) [@elricstorm](https://www.ruby-forum.com/u/elricstorm)\
**Post date:** [January 18, 2010, 11:38pm UTC](https://www.ruby-forum.com/t/question-about-some-changes-from-ruby-1-8-6-to-ruby-1-9/181832/2 "2010-01-18T23:38:22Z")

</div>

On Jan 18, 2010, at 5:15 PM, Alpha B. wrote:

> :conditions =\> ‘pages.parent\_id IS NULL and pages.subpage\_id IS NULL’,  
> :order =\> ‘pages.position’,  
> :include =\> [:subpages, :subofsubs]

Those two :include options are not equivalent. You want:

:include =\> {:subpages =\> :subofsubs}

for the Ruby 1.9 version to be equivalent to the 1.8 version.

Gary W.
