putpat / rockstar

Rockstar is a wrapper for the audioscrobbler v2.0 (last.fm) web services. This gem includes scrobbling with the new api.
MIT License
82 stars 29 forks source link

Undefined method 'to_plain_text' for nil:Nilclass #7

Closed whatwho closed 13 years ago

whatwho commented 13 years ago

Hello,

when I want to set an album object's info, I get the next error: Rockstar::Album.new('Thievery Corporation', 'Radio Retalation').load_info

NoMethodError: undefined method `to_plain_text' for nil:NilClass

There's no checking in album's summary info, if it's nil or not, or maybe the API changed.

Thanks in advance, Miki

bitboxer commented 13 years ago

Some albums don't have a summary or a content node ( Closed by f11efe56cfd3c1e59558abca1d8dc461e169c330 )

whatwho commented 13 years ago

It's ok, but in that case load_info raises an undhandled exception, and I can't use it for these types of albums.

bitboxer commented 13 years ago

yes, i know. the comment was actually the git commit comment that closes this issue :)

bitboxer commented 13 years ago

A new version of the gem was uploaded to rubygems. Grab 0.5.1, that fixes this issue.

whatwho commented 13 years ago

Thank you very much! :)