Skip Menu |

Preferred bug tracker

Please visit the preferred bug tracker to report your issue.

This queue is for tickets about the TMDB CPAN distribution.

Report information
The Basics
Id: 79921
Status: resolved
Priority: 0/
Queue: TMDB

People
Owner: MITHUN [...] cpan.org
Requestors: brainkiller [...] gmail.com
Cc:
AdminCc:

Bug Information
Severity: (no value)
Broken in: (no value)
Fixed in: (no value)



Subject: Feature request: add similar_movies
Date: Fri, 28 Sep 2012 22:04:34 +0200
To: bug-TMDB [...] rt.cpan.org
From: Brainkiller <brainkiller [...] gmail.com>
Hi, Please add support for the call to |similar_movies as it is now supported in the API | You can use the following patch as example: ----------------------------------------------------------- --- Movie.pm.org 2012-09-28 22:03:33.942167716 +0200 +++ Movie.pm 2012-09-27 19:59:18.026397296 +0200 @@ -87,6 +87,26 @@ } ## end sub alternative_titles ## ==================== +## SIMILAR MOVIES +## ==================== +sub similar_movies { + my ($self) = @_; + my $params = {}; + $params->{lang} = $self->session->lang if $self->session->lang; + + my $response = $self->session->talk( + { + method => 'movie/' . $self->id . '/similar_movies', + params => $params + } + ); + my $result = $response->{'results'}; + + return @$result if wantarray; + return $result; +} + +## ==================== ## CAST ## ==================== sub cast { ----------------------------------------------------------- Regards, Brainkiller
v0.06 is on it's way to your mirror. Thanks for the patch! -- Mithun