summaryrefslogtreecommitdiffstats
path: root/lib/class/catalog.class.php
diff options
context:
space:
mode:
authorPaul Arthur <paul.arthur@flowerysong.com>2012-04-09 16:18:13 -0400
committerPaul Arthur <paul.arthur@flowerysong.com>2012-04-09 16:18:13 -0400
commitec9389f5c64f7de1d985d364b55a7872580034c2 (patch)
tree57f572f384315853c93c1b5a51f91fff91990895 /lib/class/catalog.class.php
parent8b27b6aee2e7662f1363692f647aff2d70720063 (diff)
downloadampache-ec9389f5c64f7de1d985d364b55a7872580034c2.tar.gz
ampache-ec9389f5c64f7de1d985d364b55a7872580034c2.tar.bz2
ampache-ec9389f5c64f7de1d985d364b55a7872580034c2.zip
Make Art->get_from_source() static
Half the calls to it were already trying to call it as a static method anyway. The only time $this was referenced was to get the type, so pass type as a parameter.
Diffstat (limited to 'lib/class/catalog.class.php')
-rw-r--r--lib/class/catalog.class.php5
1 files changed, 3 insertions, 2 deletions
diff --git a/lib/class/catalog.class.php b/lib/class/catalog.class.php
index addf67d2..52073202 100644
--- a/lib/class/catalog.class.php
+++ b/lib/class/catalog.class.php
@@ -716,7 +716,7 @@ class Catalog extends database_object {
if (count($results)) {
// Pull the string representation from the source
- $image = $art->get_from_source($results['0']);
+ $image = Art::get_from_source($results['0'], 'album');
if (strlen($image) > '5') {
$art->insert($image, $results['0']['mime']);
// If they've enabled resizing of images generate the thumbnail now
@@ -2163,7 +2163,8 @@ class Catalog extends database_object {
$get_vars = parse_url($song['art']);
$extension = substr($get_vars['query'],strlen($get_vars['query'])-3,3);
// Pull the image
- $raw = $art->get_from_source(array('url'=>$song['art']));
+ $raw = Art::get_from_source(
+ array('url' => $song['art']), 'album');
$inserted = $art->insert($raw,'image/' . $extension);
}