drupal-check against pdfpreview-8.x-1.x-dev (4 Jul 2018)

 ------ ------------------------------------------------------------ 
  Line   src/PDFPreviewGenerator.php                                 
 ------ ------------------------------------------------------------ 
  146    Call to deprecated method addArgument() of class            
         Drupal\imagemagick\Plugin\ImageToolkit\ImagemagickToolkit.  
  147    Call to deprecated method addArgument() of class            
         Drupal\imagemagick\Plugin\ImageToolkit\ImagemagickToolkit.  
  148    Call to deprecated method addArgument() of class            
         Drupal\imagemagick\Plugin\ImageToolkit\ImagemagickToolkit.  
  149    Call to deprecated method addArgument() of class            
         Drupal\imagemagick\Plugin\ImageToolkit\ImagemagickToolkit.  
  151    Call to deprecated method setDestinationFormat() of class   
         Drupal\imagemagick\Plugin\ImageToolkit\ImagemagickToolkit.  
  154    Call to deprecated method setDestinationFormat() of class   
         Drupal\imagemagick\Plugin\ImageToolkit\ImagemagickToolkit.  
  156    Call to deprecated method setSourceFormat() of class        
         Drupal\imagemagick\Plugin\ImageToolkit\ImagemagickToolkit.  
  157    Call to deprecated method setSourceLocalPath() of class     
         Drupal\imagemagick\Plugin\ImageToolkit\ImagemagickToolkit.  
 ------ ------------------------------------------------------------ 

 ------ --------------------------------------------------------- 
  Line   src/Plugin/Field/FieldFormatter/PDFPreviewFormatter.php  
 ------ --------------------------------------------------------- 
  100    Call to deprecated method urlInfo() of class             
         Drupal\Core\Entity\EntityInterface.                      
 ------ --------------------------------------------------------- 

                                                                                
 [ERROR] Found 9 errors                                                         
                                                                               

Comments

waverate created an issue. See original summary.

brandonratz’s picture

Fixes method compatibility for use with ImageMagick 3.x

waverate’s picture

Status: Active » Needs work

Patch at #3 fixes deprecated ImageMagick methods. However, there is still a deprecated method urlInfo().

------ ---------------------------------------------------------------------------------- 
  Line   src/Plugin/Field/FieldFormatter/PDFPreviewFormatter.php                           
 ------ ---------------------------------------------------------------------------------- 
  100    Call to deprecated method urlInfo() of class Drupal\Core\Entity\EntityInterface.  
 ------ ---------------------------------------------------------------------------------- 

                                                                                                                        
 [ERROR] Found 1 error                                                                                                  
Snehal Brahmbhatt’s picture

Status: Needs work » Needs review
StatusFileSize
new597 bytes

@waverate, Please find the below-attached patch, & let me know your views for the same.

thanks!.

waverate’s picture

@snehal.addweb. Patch at #5 fixes the deprecated method urlInfo(). Can you please re-roll the patch to include patch #3?

waverate’s picture

Status: Needs review » Needs work
e.bogatyrev’s picture

Status: Needs work » Needs review
StatusFileSize
new2.49 KB

Hi @waverate, all,

I combined two patches above (#3, #5) into one and added fix for deprecated functions

 ------ -------------------------------------------------------
  Line   src/PDFPreviewGenerator.php
 ------ -------------------------------------------------------
  107    Call to deprecated function file_unmanaged_delete().
  145    Call to deprecated function file_prepare_directory().
 ------ -------------------------------------------------------

Please review.

Thanks

waverate’s picture

Status: Needs review » Reviewed & tested by the community

Patch at #8 applied without errors. drupal-check returns:

 [OK] No errors                                                                 

Thank you @e.bogatyrev.

  • mstrelan committed 660cd8a on 8.x-1.x
    Issue #3052005 by Snehal Brahmbhatt, brandonratz, e.bogatyrev, waverate...
mstrelan’s picture

Status: Reviewed & tested by the community » Fixed

I made a few commits and forgot to credit everyone so adding a dummy commit as above and closing this issue. Thanks everyone!

Status: Fixed » Closed (fixed)

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