magnolia-fan/musicbrainz — pull request #15 by Applicat (2013-01-24 13:25:06+00:00)
Title: Calculate last day of month correctly. refs #14

Regarding issue #14.

If the musicbrainz api is only returning year and month as date like in the following response (1995-04) the day will be always 31:

http://musicbrainz.org/ws/2/release-group?artist=309c62ba-7a22-4277-9f67-4a162526d18a

But not all months have 31 days.

That's why I added a calculation of the last day through Date.new(year, month, -1).