Skip to content

Commit

Permalink
turned meta_name into a class method as well
Browse files Browse the repository at this point in the history
  • Loading branch information
polettix authored and rjbs committed Apr 1, 2011
1 parent 81875e1 commit 06bfbe5
Showing 1 changed file with 10 additions and 1 deletion.
11 changes: 10 additions & 1 deletion lib/Software/License/Custom.pm
Expand Up @@ -53,9 +53,16 @@ sub section_data {

sub name { shift->_fill_in('NAME') }
sub url { shift->_fill_in('URL') }
sub meta_name { shift->_fill_in('META_NAME') }
sub meta2_name { shift->_fill_in('META2_NAME') }

# This is (also) a class method in the other modules, so we stick to this
# convention and the tests will be happy.
sub meta_name {
my $self = shift;
return 'custom' unless ref $self;
return $self->_fill_in('META_NAME')
}

1;
__END__
Expand All @@ -66,3 +73,5 @@ specifying all aspects related to a software license in a custom file.
This allows for setting custom dates, notices, etc. while still preserving
compatibility with all places where L<Software::License> is used, e.g.
L<Dist::Zilla>.
=cut

0 comments on commit 06bfbe5

Please sign in to comment.