Fix importing application-specific PIP files
authorMatthias Schmidt <gravatronics@live.com>
Sat, 24 Nov 2018 08:36:56 +0000 (09:36 +0100)
committerMatthias Schmidt <gravatronics@live.com>
Sat, 24 Nov 2018 08:36:56 +0000 (09:36 +0100)
See #2616

wcfsetup/install/files/lib/system/devtools/pip/DevtoolsPip.class.php

index 1c762ecb509dd2131f14835399c522c1294c0231..26f92a9c89f3154e3fd0341412309b94467ac189 100644 (file)
@@ -252,7 +252,9 @@ class DevtoolsPip extends DatabaseObjectDecorator {
                $tar = $project->getPackageArchive()->getTar();
                $tar->reset();
                
-               $instructions = [];
+               $instructions = [
+                       'value' => $target
+               ];
                
                if ($project->isCore()) {
                        switch ($pluginName) {
@@ -310,24 +312,18 @@ class DevtoolsPip extends DatabaseObjectDecorator {
                                                }
                                        }
                                        
-                                       $instructions['value'] = $defaultFilename;
-                                       
                                        break;
                                
                                case 'language':
                                        $filename = "wcfsetup/install/lang/{$target}";
                                        $tar->registerFile($filename, $project->path . $filename);
                                        
-                                       $instructions['value'] = $filename;
-                                       
                                        break;
                                        
                                default:
                                        $filename = "com.woltlab.wcf/{$target}";
                                        $tar->registerFile($filename, $project->path . $filename);
                                        
-                                       $instructions['value'] = $filename;
-                                       
                                        break;
                        }
                }
@@ -389,8 +385,6 @@ class DevtoolsPip extends DatabaseObjectDecorator {
                                                }
                                        }
                                        
-                                       $instructions['value'] = $defaultFilename;
-                                       
                                        break;
                                
                                default:
@@ -403,8 +397,6 @@ class DevtoolsPip extends DatabaseObjectDecorator {
                                                $tar->registerFile($filename, $project->path . $filename);
                                        }
                                        
-                                       $instructions['value'] = $filename;
-                                       
                                        break;
                        }
                }