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

PHP Notice/Warning #58

Open
monstercodeDev opened this issue May 30, 2017 · 3 comments
Open

PHP Notice/Warning #58

monstercodeDev opened this issue May 30, 2017 · 3 comments
Milestone

Comments

@monstercodeDev
Copy link

monstercodeDev commented May 30, 2017

Hi,

we noticed the following php notices / warning in our log file:

PHP Notice Trying to get property of non-object in .... slack/includes/post-type.php on line 464
PHP Notice: Uninitialized string offset: 0 in ... slack/includes/post-type.php on line 469
PHP Warning: Illegal string offset 'active' in ... slack/includes/post-type.php on line 469

On line 464 there is the get_current_screen() function, which is defined on most admin pages, but not all. Here - if I'm right - it exists, but returns with NULL.

On line 469 the get_post_meta() function will return as string, but the code checks it as an array.

Thanks,

cc @lkraav

@gedex gedex added this to the 0.6.1 milestone May 30, 2017
@gedex
Copy link
Owner

gedex commented May 30, 2017

Thanks for the report, will take a look.

@lkraav
Copy link

lkraav commented Jun 19, 2017

@gedex any updates here?

lkraav added a commit to lkraav/wp-slack that referenced this issue Jun 28, 2017
@lkraav
Copy link

lkraav commented Jun 28, 2017

Figured it out, it's about calling post class functions (aka loading post entries) during an AJAX call.

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

No branches or pull requests

3 participants