CC-5709: Airtime Analyzer

* Fixed breakage
This commit is contained in:
Albert Santoni 2014-03-17 10:25:26 -04:00
parent e1f69b26af
commit f7cb923ceb
1 changed files with 2 additions and 2 deletions

View File

@ -115,7 +115,8 @@ class Rest_MediaController extends Zend_Rest_Controller
$file = CcFilesQuery::create()->findPk($id);
if ($file)
{
$fileFromJson = json_decode($this->getRequest()->getRawBody(), true);
$fileFromJson = $file->fromArray($this->validateRequestData(json_decode($this->getRequest()->getRawBody(), true)),
BasePeer::TYPE_FIELDNAME);
//Our RESTful API takes "full_path" as a field, which we then split and translate to match
//our internal schema. Internally, file path is stored relative to a directory, with the directory
@ -136,7 +137,6 @@ class Rest_MediaController extends Zend_Rest_Controller
}
}
$file->fromArray($this->validateRequestData(json_decode($fileFromJson, true)), BasePeer::TYPE_FIELDNAME);
$now = new DateTime("now", new DateTimeZone("UTC"));
$file->setDbMtime($now);
$file->save();