What about

```ruby
@item = Item.new(:gallery_id => find_gallery.try(:id))
```