CC-4610: Creating recording show will generate lots of exception in zendphp.log

- fixed
This commit is contained in:
James 2012-10-19 17:30:54 -04:00
parent 2bab46a12e
commit a9df8cd7f2
2 changed files with 5 additions and 4 deletions

View File

@ -1128,7 +1128,6 @@ SQL;
} }
} else { } else {
if ($isAdminOrPM) { if ($isAdminOrPM) {
Logging::info( $data );
Application_Model_Show::create($data); Application_Model_Show::create($data);
} }

View File

@ -198,7 +198,9 @@ class Application_Model_ShowBuilder
} elseif (intval($p_item["si_record"]) === 1) { } elseif (intval($p_item["si_record"]) === 1) {
$row["record"] = true; $row["record"] = true;
if (Application_Model_Preference::GetUploadToSoundcloudOption()) { // at the time of creating on show, the recorded file is not in the DB yet.
// therefore, 'si_file_id' is null. So we need to check it.
if (Application_Model_Preference::GetUploadToSoundcloudOption() && isset($p_item['si_file_id'])) {
$file = Application_Model_StoredFile::Recall( $file = Application_Model_StoredFile::Recall(
$p_item['si_file_id']); $p_item['si_file_id']);
if (isset($file)) { if (isset($file)) {
@ -398,7 +400,7 @@ class Application_Model_ShowBuilder
//see if the displayed show instances have changed. (deleted, //see if the displayed show instances have changed. (deleted,
//empty schedule etc) //empty schedule etc)
if ($outdated === false && count($instances) if ($outdated === false && count($instances)
!== count($currentInstances)) { !== count($currentInstances)) {
Logging::debug("show instances have changed."); Logging::debug("show instances have changed.");
$outdated = true; $outdated = true;
@ -459,7 +461,7 @@ class Application_Model_ShowBuilder
$display_items[] = $row; $display_items[] = $row;
} }
if ($current_id !== -1 && if ($current_id !== -1 &&
!in_array($current_id, $this->showInstances)) { !in_array($current_id, $this->showInstances)) {
$this->showInstances[] = $current_id; $this->showInstances[] = $current_id;
} }