Skip to content

Commit

Permalink
Tweaked documentation. Bumped to version 0.02.
Browse files Browse the repository at this point in the history
  • Loading branch information
davorg committed Aug 26, 2010
1 parent 32b28ff commit 72592b5
Showing 1 changed file with 7 additions and 4 deletions.
11 changes: 7 additions & 4 deletions lib/Net/Songkick.pm
Original file line number Diff line number Diff line change
Expand Up @@ -44,7 +44,7 @@ package Net::Songkick;
use strict;
use warnings;

our $VERSION = '0.01';
our $VERSION = '0.02';

use Moose;

Expand Down Expand Up @@ -120,8 +120,11 @@ the events returned are supported for the full list see
L<http://www.songkick.com/developer/event-search>.
In addition, this method takes an extra parameter, B<format>, which control
the format of the data returned. This can be either I<xml> or I<json>. If this
parameter is omitted, then I<xml> is assumed.
the format of the data returned. This can be either I<xml>, I<json> or
I<perl>. If it is either I<xml> or I<json> then the method will return the
raw XML or JSON from the Songkick API. If ii is I<perl> then this method
will return a list of L<Net::Songkick::Event> objects. If this parameter is
omitted, then I<perl> is assumed.
=cut

Expand All @@ -148,7 +151,7 @@ sub get_events {
foreach ($xp->findnodes('//event')) {
push @$evnts, Net::Songkick::Event->new_from_xml($_);
}
return $evnts;
return wantarray ? @$evnts : $evnts;
} else {
return $resp;
}
Expand Down

0 comments on commit 72592b5

Please sign in to comment.