diff options
author | Paul Arthur <paul.arthur@flowerysong.com> | 2013-01-25 21:08:24 -0500 |
---|---|---|
committer | Paul Arthur <paul.arthur@flowerysong.com> | 2013-01-25 21:45:47 -0500 |
commit | 1069d54c85149ff1cb51563d6a1fc471695f8b47 (patch) | |
tree | e5c22762ef4d6c90dcdb3646a04de26e21ad071c /lib/class/tmpplaylist.class.php | |
parent | cad1380737f7ffcfa82d46ab3066823435a48a5d (diff) | |
download | ampache-1069d54c85149ff1cb51563d6a1fc471695f8b47.tar.gz ampache-1069d54c85149ff1cb51563d6a1fc471695f8b47.tar.bz2 ampache-1069d54c85149ff1cb51563d6a1fc471695f8b47.zip |
Move clean functions into their respective classes
Uniformly name them gc()
Diffstat (limited to 'lib/class/tmpplaylist.class.php')
-rw-r--r-- | lib/class/tmpplaylist.class.php | 5 |
1 files changed, 3 insertions, 2 deletions
diff --git a/lib/class/tmpplaylist.class.php b/lib/class/tmpplaylist.class.php index f216a7d0..2da411cf 100644 --- a/lib/class/tmpplaylist.class.php +++ b/lib/class/tmpplaylist.class.php @@ -278,12 +278,13 @@ class tmpPlaylist extends database_object { } // session_clean /** - * clean + * gc * This cleans up old data */ - public static function clean() { + public static function gc() { self::prune_playlists(); self::prune_tracks(); + Dba::write("DELETE FROM `tmp_playlist_data` USING `tmp_playlist_data` LEFT JOIN `song` ON `tmp_playlist_data`.`object_id` = `song`.`id` WHERE `song`.`id` IS NULL"); } /** |