line |
stmt |
bran |
cond |
sub |
pod |
time |
code |
1
|
|
|
|
|
|
|
package API::Instagram::Media::Comment; |
2
|
|
|
|
|
|
|
|
3
|
|
|
|
|
|
|
# ABSTRACT: Instagram Media Comment Object |
4
|
|
|
|
|
|
|
|
5
|
15
|
|
|
15
|
|
90
|
use Moo; |
|
15
|
|
|
|
|
27
|
|
|
15
|
|
|
|
|
107
|
|
6
|
15
|
|
|
15
|
|
5985
|
use Time::Moment; |
|
15
|
|
|
|
|
32
|
|
|
15
|
|
|
|
|
3793
|
|
7
|
|
|
|
|
|
|
|
8
|
|
|
|
|
|
|
has id => ( is => 'ro', required => 1 ); |
9
|
|
|
|
|
|
|
has from => ( is => 'ro', required => 1, coerce => sub { API::Instagram->instance->user( $_[0] ) } ); |
10
|
|
|
|
|
|
|
has text => ( is => 'ro', required => 1 ); |
11
|
|
|
|
|
|
|
has media => ( is => 'ro', required => 1 ); |
12
|
|
|
|
|
|
|
has created_time => ( is => 'ro', coerce => sub { Time::Moment->from_epoch( $_[0] ) } ); |
13
|
|
|
|
|
|
|
|
14
|
|
|
|
|
|
|
sub remove { |
15
|
1
|
|
|
1
|
1
|
4162
|
my $self = shift; |
16
|
1
|
|
|
|
|
11
|
my $url = sprintf "media/%s/comments/%s", $self->media->id, $self->id; |
17
|
1
|
|
|
|
|
27
|
$self->media->_api->_del( $url ) |
18
|
|
|
|
|
|
|
} |
19
|
|
|
|
|
|
|
|
20
|
|
|
|
|
|
|
1; |
21
|
|
|
|
|
|
|
|
22
|
|
|
|
|
|
|
__END__ |