summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rwxr-xr-xdocs/CHANGELOG2
-rw-r--r--lib/class/stream.class.php19
2 files changed, 10 insertions, 11 deletions
diff --git a/docs/CHANGELOG b/docs/CHANGELOG
index d94002ec..c0ae3b74 100755
--- a/docs/CHANGELOG
+++ b/docs/CHANGELOG
@@ -4,6 +4,8 @@
--------------------------------------------------------------------------
v.3.4-Alpha4
+ - Fixed problem with invalid urls populated to localplay methods
+ under certin conditions
- Fixed Album Art dump bin script
- Added paging to the Playlist Song view
- Fixed error on catalog Update All
diff --git a/lib/class/stream.class.php b/lib/class/stream.class.php
index 3b5d24cb..faadd2b2 100644
--- a/lib/class/stream.class.php
+++ b/lib/class/stream.class.php
@@ -451,17 +451,14 @@ class Stream {
//HACK!!!
// Yea.. you know the baby jesus... he's crying right meow
foreach ($this->songs as $song_id) {
- $this->objects[] = new Song($song_id);
- }
-
-
- // Foreach the stuff we've got and add it
- foreach ($this->objects as $object) {
- $localplay->add($object);
- }
-
- foreach ($this->urls as $url) {
- $localplay->add($url);
+ if ($song_id > 0) {
+ $song = new Song($song_id);
+ $localplay->add($song);
+ }
+ else {
+ $url = array_shift($this->urls);
+ $localplay->add($url);
+ }
}
$localplay->play();