src/Modify/Compress/FindCompression.php 1 location
                
                
                    
                                                
                                                    
                                |  | @@ 95-104 (lines=10) @@ | 
                                                            
                                    | 92 |  |      * | 
                                                            
                                    | 93 |  |      * @return FileNodeInterface | 
                                                            
                                    | 94 |  |      */ | 
                                                            
                                    | 95 |  |     public function modify(FileNodeInterface $file, array $options = []) | 
                                                            
                                    | 96 |  |     { | 
                                                            
                                    | 97 |  |         if (!$this->canModify($file) || !($file instanceof LocalFileNodeInterface)) { | 
                                                            
                                    | 98 |  |             throw new InvalidArgumentException("The supplied file: '$file' does not implement LocalFileNodeInterface'"); | 
                                                            
                                    | 99 |  |         } | 
                                                            
                                    | 100 |  |  | 
                                                            
                                    | 101 |  |         $file->setCompression($this->getCompression($file)); | 
                                                            
                                    | 102 |  |  | 
                                                            
                                    | 103 |  |         return $file; | 
                                                            
                                    | 104 |  |     } | 
                                                            
                                    | 105 |  | } | 
                                                            
                                    | 106 |  |  | 
                                                                        
                 
                                                            
                    
src/Modify/Encoding/FindEncoding.php 1 location
                
                
                    
                                                
                                                    
                                |  | @@ 80-91 (lines=12) @@ | 
                                                            
                                    | 77 |  |      * @return FileNodeInterface | 
                                                            
                                    | 78 |  |      * @throws InvalidArgumentException | 
                                                            
                                    | 79 |  |      */ | 
                                                            
                                    | 80 |  |     public function modify(FileNodeInterface $file, array $options = []) | 
                                                            
                                    | 81 |  |     { | 
                                                            
                                    | 82 |  |         if (!$this->canModify($file) || !($file instanceof LocalFileNodeInterface)) { | 
                                                            
                                    | 83 |  |             throw new InvalidArgumentException( | 
                                                            
                                    | 84 |  |                 "The specified file: '$file' does not implement LocalFileNodeInterface'" | 
                                                            
                                    | 85 |  |             ); | 
                                                            
                                    | 86 |  |         } | 
                                                            
                                    | 87 |  |  | 
                                                            
                                    | 88 |  |         $file->setEncoding($this->getEncoding($file)); | 
                                                            
                                    | 89 |  |  | 
                                                            
                                    | 90 |  |         return $file; | 
                                                            
                                    | 91 |  |     } | 
                                                            
                                    | 92 |  | } | 
                                                            
                                    | 93 |  |  |