# Error in GITHUB

**URL:** <https://discuss.rubyonrails.org/t/error-in-github/70514>\
**Category:** rubyonrails-talk\
**Created:** [April 14, 2015, 8:45am UTC](https://discuss.rubyonrails.org/t/error-in-github/70514 "2015-04-14T08:45:35Z")\
**Posts on this page:** 2\
**Page:** 1

<div class="post-metadata">

**Author:** ![Kagiso\_Samuel\_Ramolo](https://avatars.discourse-cdn.com/v4/letter/k/ad7895/32.png) [@Kagiso\_Samuel\_Ramolo](https://discuss.rubyonrails.org/u/Kagiso_Samuel_Ramolo)\
**Post date:** [April 14, 2015, 8:45am UTC](https://discuss.rubyonrails.org/t/error-in-github/70514/1 "2015-04-14T08:45:35Z")

</div>

Hi, all

Please help with the following code, I think one line is giving the error. What can I do below to make the code to output 1,7,“Testing”, nil, 321

```ruby
def output_values(*values)

values.each do |value|

if value == nil

puts "Nil value"

return

end

puts value

end

end
```

---

<div class="post-metadata">

**Author:** ![Colin\_Law](https://avatars.discourse-cdn.com/v4/letter/c/b9e5f3/32.png) [@Colin\_Law](https://discuss.rubyonrails.org/u/Colin_Law)\
**Post date:** [April 14, 2015, 9:16am UTC](https://discuss.rubyonrails.org/t/error-in-github/70514/2 "2015-04-14T09:16:03Z")

</div>

> Hi, all
> 
> Please help with the following code, I think one line is giving the error. What can I do below to make the code to output 1,7,"Testing", nil, 321
> 
> def output\_values(\*values) &nbsp;&nbsp;values.each do |value| &nbsp;&nbsp;&nbsp;&nbsp;if value == nil &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;puts "Nil value" &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;return

Why have you got a return here?

Colin
