summaryrefslogtreecommitdiffstats
path: root/lib/class
diff options
context:
space:
mode:
Diffstat (limited to 'lib/class')
-rw-r--r--lib/class/radio.class.php7
-rw-r--r--lib/class/random.class.php4
-rw-r--r--lib/class/rating.class.php4
3 files changed, 10 insertions, 5 deletions
diff --git a/lib/class/radio.class.php b/lib/class/radio.class.php
index 7665c887..99232944 100644
--- a/lib/class/radio.class.php
+++ b/lib/class/radio.class.php
@@ -1,7 +1,7 @@
<?php
/*
- Copyright 2001 - 2007 Ampache.org
+ Copyright Ampache.org
All Rights Reserved
This program is free software; you can redistribute it and/or
@@ -168,6 +168,11 @@ class Radio {
Error::add('url','Invalid URL must be http:// or https://');
}
+ // If they specified other try to use that
+ if (strlen($data['other_genre'])) {
+ $data['genre'] = Catalog::check_genre($data['other_genre']);
+ }
+
// Make sure it's a real genre
$genre = new Genre($data['genre']);
if (!$genre->name) {
diff --git a/lib/class/random.class.php b/lib/class/random.class.php
index 8a042bad..0865f23f 100644
--- a/lib/class/random.class.php
+++ b/lib/class/random.class.php
@@ -1,7 +1,7 @@
<?php
/*
- Copyright 2001 - 2007 Ampache.org
+ Copyright Ampache.org
All Rights Reserved
This program is free software; you can redistribute it and/or
@@ -281,7 +281,7 @@ class Random {
} // end if matchlist
switch ($data['random_type']) {
- case 'full_aldum':
+ case 'full_album':
$query = "SELECT `album`.`id` FROM `song` INNER JOIN `album` ON `song`.`album`=`album`.`id` " .
"WHERE $where GROUP BY `song`.`album` ORDER BY RAND() $limit_sql";
$db_results = Dba::query($query);
diff --git a/lib/class/rating.class.php b/lib/class/rating.class.php
index d844cea1..51555c10 100644
--- a/lib/class/rating.class.php
+++ b/lib/class/rating.class.php
@@ -1,7 +1,7 @@
<?php
/*
- Copyright (c) 2001 - 2008 Ampache.org
+ Copyright (c) Ampache.org
All rights reserved.
This program is free software; you can redistribute it and/or
@@ -45,7 +45,7 @@ class Rating {
$this->type = Dba::escape($type);
// Check for the users rating
- if ($rating == $this->get_user($GLOBALS['user']->id)) {
+ if ($rating = $this->get_user($GLOBALS['user']->id)) {
$this->rating = $rating;
$this->preciserating = $rating;
}