mirror of
https://git.FreeBSD.org/ports.git
synced 2024-12-24 04:33:24 +00:00
Fix the LastFM plugin. It was broken due to the FreeBSD version of JSON::XS
being newer than expected and the general workaround not being implemented in this plugin. Submitted by: tdb
This commit is contained in:
parent
ab7f066e29
commit
b2f60ceeec
Notes:
svn2git
2021-03-31 03:12:20 +00:00
svn path=/head/; revision=221305
@ -7,7 +7,7 @@
|
||||
|
||||
PORTNAME= squeezecenter
|
||||
PORTVERSION= 7.2.0
|
||||
PORTREVISION= 1
|
||||
PORTREVISION= 2
|
||||
CATEGORIES= audio
|
||||
MASTER_SITES= http://downloads.slimdevices.com/SqueezeCenter_v${PORTVERSION}/
|
||||
DISTNAME= ${PORTNAME}-${PORTVERSION:S/.0//}-noCPAN
|
||||
|
@ -0,0 +1,23 @@
|
||||
|
||||
$FreeBSD$
|
||||
|
||||
--- Slim/Plugin/LastFM/ProtocolHandler.pm.orig
|
||||
+++ Slim/Plugin/LastFM/ProtocolHandler.pm
|
||||
@@ -7,7 +7,7 @@
|
||||
use strict;
|
||||
use base qw(Slim::Player::Protocols::HTTP);
|
||||
|
||||
-use JSON::XS qw(from_json);
|
||||
+use JSON::XS qw(decode_json);
|
||||
use URI::Escape qw(uri_escape_utf8);
|
||||
|
||||
use Slim::Player::Playlist;
|
||||
@@ -155,7 +155,7 @@
|
||||
my $client = $http->params->{client};
|
||||
my $params = $http->params->{params};
|
||||
|
||||
- my $track = eval { from_json( $http->content ) };
|
||||
+ my $track = eval { decode_json( $http->content ) };
|
||||
|
||||
if ( $@ || $track->{error} ) {
|
||||
# We didn't get the next track to play
|
@ -7,7 +7,7 @@
|
||||
|
||||
PORTNAME= squeezecenter
|
||||
PORTVERSION= 7.2.0
|
||||
PORTREVISION= 1
|
||||
PORTREVISION= 2
|
||||
CATEGORIES= audio
|
||||
MASTER_SITES= http://downloads.slimdevices.com/SqueezeCenter_v${PORTVERSION}/
|
||||
DISTNAME= ${PORTNAME}-${PORTVERSION:S/.0//}-noCPAN
|
||||
|
@ -0,0 +1,23 @@
|
||||
|
||||
$FreeBSD$
|
||||
|
||||
--- Slim/Plugin/LastFM/ProtocolHandler.pm.orig
|
||||
+++ Slim/Plugin/LastFM/ProtocolHandler.pm
|
||||
@@ -7,7 +7,7 @@
|
||||
use strict;
|
||||
use base qw(Slim::Player::Protocols::HTTP);
|
||||
|
||||
-use JSON::XS qw(from_json);
|
||||
+use JSON::XS qw(decode_json);
|
||||
use URI::Escape qw(uri_escape_utf8);
|
||||
|
||||
use Slim::Player::Playlist;
|
||||
@@ -155,7 +155,7 @@
|
||||
my $client = $http->params->{client};
|
||||
my $params = $http->params->{params};
|
||||
|
||||
- my $track = eval { from_json( $http->content ) };
|
||||
+ my $track = eval { decode_json( $http->content ) };
|
||||
|
||||
if ( $@ || $track->{error} ) {
|
||||
# We didn't get the next track to play
|
Loading…
Reference in New Issue
Block a user