From c3a692d252ed0e849af90feacd2fd93bc3686d72 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Adrian=20Duli=C4=87?= Date: Tue, 8 Mar 2011 02:23:10 +0100 Subject: [PATCH] Fixed notice warnings when error_reporting set to E_ALL --- Zencoder.php | 10 +++++----- 1 file changed, 5 insertions(+), 5 deletions(-) diff --git a/Zencoder.php b/Zencoder.php index f5d7aa3..86118d9 100644 --- a/Zencoder.php +++ b/Zencoder.php @@ -35,12 +35,12 @@ class ZencoderJob { function ZencoderJob($params, $options = array()) { // Build using params if not sending request - if($options["build"]) { + if(isset($options["build"])) { $this->update_attributes($params); return true; } - if($options["url"]) $this->new_job_url = $options["url"]; + if(isset($options["url"])) $this->new_job_url = $options["url"]; $this->new_job_params = $params; $this->created = $this->create(); } @@ -75,7 +75,7 @@ function update_attributes($attributes = array()) { // Use the Label for the key if avaiable. function create_outputs($outputs = array()) { foreach($outputs as $output_attrs) { - if($output_attrs["label"]) { + if(isset($output_attrs["label"])) { $this->outputs[$output_attrs["label"]] = new ZencoderOutputFile($output_attrs); } else { $this->outputs[] = new ZencoderOutputFile($output_attrs); @@ -233,8 +233,8 @@ class ZencoderOutputNotification { var $job; function ZencoderOutputNotification($params) { - if($params["output"]) $this->output = new ZencoderOutputFile($params["output"]); - if($params["job"]) $this->job = new ZencoderJob($params["job"], array("build" => true)); + if(isset($params["output"])) $this->output = new ZencoderOutputFile($params["output"]); + if(isset($params["job"])) $this->job = new ZencoderJob($params["job"], array("build" => true)); } function catch_and_parse() {