Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Error with a non-object and the solution #2

Open
murilodbva opened this issue Jun 26, 2017 · 1 comment
Open

Error with a non-object and the solution #2

murilodbva opened this issue Jun 26, 2017 · 1 comment

Comments

@murilodbva
Copy link

This error was happening with me (including the last version '3.0.9'):

[error] 603#0: *33 FastCGI sent in stderr: "PHP message: PHP Notice: Trying to get property of non-object in .../plugins/content/phocaopengraph/phocaopengraph.php on line 161" while reading response header from upstream ...

On line 161 was:
} else if ($row->title != '') {

And I fixed with isset before:
} else if (isset($row->title) && $row->title != '') {

@PhocaCz
Copy link
Owner

PhocaCz commented Jun 26, 2017

Hi, thank you for the info, the $row->title should always exist as it is added as function parameter. But yes, there is no problem to add more protection in form of isset.

Fixed in version 3.1.0
You can download it here: https://www.phoca.cz/download/category/62-phoca-open-graph-plugin

Thank you, Jan

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants