I have sort of a silly question. I'm running SugarCRM and trying to track down an error.

I dug up the error from the httpd error log and then started checking into the code myself. The error appears to be a code issue, but since I don't know how to properly check to see if an object is valid, I'm not really sure what the correct coding should be.

The system is a FreeBSD 5.3 box with Apache 2.0.55 and PHP 5.1.2. Everything appears to run alright except when sending an email with SugarCRM then a entry in the httpd error log appears

PHP Notice: Object of class UploadFile could not be converted to int in sugar/modules/Emails/Save.php line 116

The code block looks like this in save.php

$upload_file = new UploadFile('email_attachment'.$i);

if ($upload_file == -1) { <----- Line 116
        continue;
}


Does anyone know if this is the proper way to check for an Objects existence and where I can find more information on doing so?

Thanks,

Derrick Shoemake

Reply via email to