gocodebox / gocodebox/lifterlms
Add a null check to prevent "Attempt to read property ... on null" PHP warnings.
Open
@ideadude is already working on this.
Since Nov 23, 2023.
Status: Need Information
- Dominant language
- PHP
- Stars
- 212
- Forks
- 140
- Avg merge
- 2d 14h
- Merged PRs (30d)
- 19
Description
Is your feature request related to a problem? Please describe.
Some users are reporting the following warnings from their logs:
PHP Warning: Attempt to read property "ID" on null in /wp-content/plugins/lifterlms/templates/course/tags.php on line 15
PHP Warning: Attempt to read property "post_type" on null in /wp-content/plugins/lifterlms/includes/abstracts/abstract.llms.post.model.php on line 473
Describe the solution you'd like
Add a null check to prevent this non-fatal warnings.
Describe alternatives you've considered
Just disabling PHP warnings on the server.
Contributor guide
First steps
- Read the whole issue, then the project's contributing guide.
- Comment on the issue to say you are picking it up — it saves two people doing the same work.
- Fork the repository and make your change on a branch.
- Open a pull request that references the issue number.
Assessment
This issue has not been assessed yet.