CC-4637: Media Library: Item will be removed from Playlist if it's removed from Library

-fixed
This commit is contained in:
denise 2012-11-02 17:49:32 -04:00
parent 2854dd40e0
commit 106b18bf30
2 changed files with 2 additions and 5 deletions

View File

@ -321,7 +321,7 @@ class LibraryController extends Zend_Controller_Action
if (isset($file)) {
try {
$res = $file->delete(true);
$res = $file->delete();
} catch (FileNoPermissionException $e) {
$message = $noPermissionMsg;
} catch (Exception $e) {

View File

@ -335,7 +335,7 @@ SQL;
* @param boolean $p_deleteFile
*
*/
public function delete($deleteFromPlaylist=false)
public function delete()
{
$filepath = $this->getFilePath();
@ -359,9 +359,6 @@ SQL;
Application_Model_RabbitMq::SendMessageToMediaMonitor("file_delete", $data);
}
if ($deleteFromPlaylist) {
Application_Model_Playlist::DeleteFileFromAllPlaylists($this->getId());
}
// set file_exists falg to false
$this->_file->setDbFileExists(false);
$this->_file->save();