From c48f556b7db820b61971edc7f5f0a5d1f5d45761 Mon Sep 17 00:00:00 2001 From: drigato Date: Tue, 13 Aug 2013 16:41:32 -0400 Subject: [PATCH] CC-5303: Interface freezes sometimes when using smart blocks --- airtime_mvc/application/models/Playlist.php | 7 ++++--- 1 file changed, 4 insertions(+), 3 deletions(-) diff --git a/airtime_mvc/application/models/Playlist.php b/airtime_mvc/application/models/Playlist.php index 7011a501f..7eaad0a64 100644 --- a/airtime_mvc/application/models/Playlist.php +++ b/airtime_mvc/application/models/Playlist.php @@ -505,11 +505,12 @@ SQL; foreach ($p_items as $ac) { $res = $this->insertPlaylistElement($this->buildEntry($ac, $pos)); - // update is_playlist flag in cc_files to indicate the // file belongs to a playlist or block (in this case a playlist) - $db_file = CcFilesQuery::create()->findPk($ac[0], $this->con); - $db_file->setDbIsPlaylist(true)->save($this->con); + if ($ac[1] == "audioclip") { + $db_file = CcFilesQuery::create()->findPk($ac[0], $this->con); + $db_file->setDbIsPlaylist(true)->save($this->con); + } $pos = $pos + 1; }