Problem/Motivation

Notice: Trying to access array offset on value of type bool in ckeditor_file_download() (line 653 of ckeditor/ckeditor.module).

Steps to reproduce

Proposed resolution

Move the info call out and check the value is correct.

@see possible return values of FALSE https://api.drupal.org/api/drupal/includes%21image.inc/function/image_ge...

Remaining tasks

User interface changes

API changes

Data model changes

Comments

joelpittet created an issue. See original summary.

joelpittet’s picture

Issue tags: +PHP 7.4
StatusFileSize
new551 bytes
vokiel’s picture

The initial preg_match() checks if image_get_info() should be even called. Changes in the patch forces to always do so. IMHO there should be another check.

joelpittet’s picture

That’s fair @vokiel and could you use traditional array for d7 and Uppercase NULL for codling standards?

vokiel’s picture

StatusFileSize
new496 bytes

Sorry @joelpittet for those coding standards. Fixed patch ready for review.

joelpittet’s picture

Status: Needs review » Reviewed & tested by the community

Thanks, this is reviewed and tested!

  • vokiel committed 721f099 on 7.x-1.x
    Issue #3185298 by vokiel, joelpittet: Notice: Trying to access array...
vokiel’s picture

Status: Reviewed & tested by the community » Fixed

Status: Fixed » Closed (fixed)

Automatically closed - issue fixed for 2 weeks with no activity.