-
Notifications
You must be signed in to change notification settings - Fork 2
Open
Description
ResponsiveImageStyle:flush() is called when uploading a new file to Drupal's media library. At this point the file is in a temporary folder, no flush is necessary as no resized versions have been created yet. When a new RecursiveDirectoryIterator is created with the $base_style_path equal to "temporary://styles/responsive/temporary/" it provokes an Exception, and the catch below logs the exception needlessly in the error log (no harm has been done, the error is just noise).
Suggested solution:
Return early if $source_scheme is "temporary":
$source_scheme = $scheme = StreamWrapperManager::getScheme($path);
if ($source_scheme == 'temporary') {
return $this;
}The logged error description was also unhelpful, as it says "problem finding responsive image derivatives", perhaps "flushing" would be better than "finding" for when there is a genuine problem?
Metadata
Metadata
Assignees
Labels
No labels