Bump version and update Changes
[music-tag-coveralia.git] / lib / Music / Tag / Coveralia.pm
index fe2e9c66f0908c089f3130bc0faa80d6bfe4cfa7..f7e3458c054d3b7c6c004c134f2a36d3c399cbcc 100644 (file)
@@ -5,7 +5,7 @@ use strict;
 use warnings;
 use parent qw/Music::Tag::Generic/;
 
-our $VERSION = '0.000_001';
+our $VERSION = '0.001';
 
 use HTTP::Tiny;
 use WWW::Search;
@@ -18,18 +18,18 @@ my $ht = HTTP::Tiny->new(agent => "Music-Tag-Coveralia/$VERSION");
 sub get_tag {
        my ($self) = @_;
 
-       my $album = $self->info->get_data('album');
+       my $album = $self->info->album;
        my $ws = WWW::Search->new('Coveralia::Albums');
        $self->status(1, "Searching coveralia for the album $album");
        $ws->native_query(WWW::Search::escape_query($album));
        while (my $res = $ws->next_result) {
                $self->status(1, 'Found album ' . $res->title . ' by ' . $res->artist);
-               next if $self->info->has_data('artist') && $self->info->get_data('artist') ne $res->artist;
+               next if $self->info->has_data('artist') && $self->info->artist ne $res->artist;
                $self->status(0, 'Selected album ' . $res->title . ' by ' . $res->artist);
                if ($res->cover('frontal')) {
                        my $resp = $ht->get($res->cover('frontal'));
                        last unless $resp->{success};
-                       $self->info->set_data(picture => {_Data => $resp->{content}});
+                       $self->info->picture({_Data => $resp->{content}});
                        $self->tagchange('picture');
                }
                last
@@ -96,7 +96,7 @@ Marius Gavrilescu, E<lt>marius@ieval.roE<gt>
 
 =head1 COPYRIGHT AND LICENSE
 
-Copyright (C) 2014 by Marius Gavrilescu
+Copyright (C) 2014-2015 by Marius Gavrilescu
 
 This library is free software; you can redistribute it and/or modify
 it under the same terms as Perl itself, either Perl version 5.20.1 or,
This page took 0.009491 seconds and 4 git commands to generate.