Skip to main content

This site requires you to update your browser. Your browsing experience maybe affected by not having the most up to date version.

We've moved the forum!

Please use forum.silverstripe.org for any new questions (announcement).
The forum archive will stick around, but will be read only.

You can also use our Slack channel or StackOverflow to ask for help.
Check out our community overview for more options to contribute.

Customising the CMS /

Moderators: martimiz, Sean, Ed, biapar, Willr, Ingo, swaiba

Object of class Image could not be converted to int


Go to End


3 Posts   1512 Views

Avatar
_Vince

Community Member, 165 Posts

6 January 2010 at 10:11am

I'm intermittently getting this warning. I've only seen it since upgrading to 2.3.4

How do I fix this?

[Notice] Object of class Image could not be converted to int
GET /uss/

Line 1894 in C:\xampplite\htdocs\uss\sapphire\core\model\DataObject.php

1894 				if((!isset($this->record[$fieldName]) && $val) || (isset($this->record[$fieldName]) && $this->record[$fieldName] != $val)) {
1895 					// Value has changed as well, not just the type
1896 					$this->changed[$fieldName] = 2;
1897 				}

Avatar
Willr

Forum Moderator, 5523 Posts

6 January 2010 at 10:30am

Could you post the backtrace. Do you have any custom code on the page that could be causing this error?

Avatar
_Vince

Community Member, 165 Posts

6 January 2010 at 11:02am

Cheers, next time the warning comes up I'll put up the backtrace. :)