Mercurial > pub > buggler
diff lib/Benzin/Bugzilla/BugComment.pm @ 9:cc7244ab1b9f
implemented time reports on bugs
author | cin |
---|---|
date | Sat, 05 Sep 2015 22:01:12 +0300 |
parents | ff9c0c788382 |
children |
line wrap: on
line diff
--- a/lib/Benzin/Bugzilla/BugComment.pm Fri Sep 04 19:42:15 2015 +0300 +++ b/lib/Benzin/Bugzilla/BugComment.pm Sat Sep 05 22:01:12 2015 +0300 @@ -4,37 +4,35 @@ my @fields; BEGIN { - @fields = qw( - id - bug_id - attachment_id - count - text - creator - creation_time - is_private - is_markdown - ); + @fields = qw( + id + bug_id + attachment_id + count + text + creator + creation_time + is_private + is_markdown + ); } -use constant { - BUG_FIELDS => \@fields -}; +use constant { COMMENT_FIELDS => \@fields }; use IMPL::declare { - base => [ - 'IMPL::Object::Fields' => undef - ] + base => [ + 'IMPL::Object::Fields' => undef + ] }; use fields @fields; sub CTOR { - my SELF $this = shift; - my $data = shift; - - $this->{$_} = $data->{$_} foreach grep exists $data->{$_}, SELF->BUG_FIELDS; + my SELF $this = shift; + my $data = shift; + + $this->{$_} = $data->{$_} + foreach grep exists $data->{$_}, @{ SELF->COMMENT_FIELDS }; } - 1;