if

Hi there guys!

Is there any way to simplify this if condition.....

if session[:id] == 1 || session[:id] == 2 || session[:id] == 5
  some codes here..
end

is there something like.. if session[:id] == [1,2,5]???

Any help would be deeply appreciated. Thank You =)

if [1,2,5].include? session[:id[
    # ...
end

-- Ezra Zygmuntowicz -- Lead Rails Evangelist
-- ez@engineyard.com
-- Engine Yard, Serious Rails Hosting
-- (866) 518-YARD (9273)

Thanks so much.. =)