kylejginavan / youtube_it

An object-oriented Ruby wrapper for the YouTube GData API
http://groups.google.com/group/ruby-youtube-library
595 stars 223 forks source link

README bug: "upload_token" example fails. #124

Closed epitron closed 11 years ago

epitron commented 12 years ago

Hi there!

I discovered that the upload_token example in the README is broken. It says to use the following parameters to the method:

:title => "title", :description => "description", :category => "People", :tags => ["test"]

This results in a somewhat unilluminating error message:

NoMethodError: undefined methodjoin' for nil:NilClass`

After scratching my head a bit, I discovered that there's no :tags option -- it should be called :keywords.

Here are some possible solutions:

  1. If :keywords isn't supplied, use :tags... because it's just less typing!
  2. Check that all the required options are there before trying to use them, and if not, raise a more informative exception.
  3. Fix the README and hope nobody mistypes their options by accident. :)

Thanks!

chebyte commented 11 years ago

thanks you are right the options was keywords

epitron commented 11 years ago

I take it you opted for solution #3? :)