[gnome-builder] npm: fix build target usage



commit 8987d5e0873d66fc0a958b2523f61ca6de947bf4
Author: Christian Hergert <chergert redhat com>
Date:   Mon Jan 21 11:33:59 2019 -0800

    npm: fix build target usage

 src/plugins/npm/npm_plugin.py | 4 ++--
 1 file changed, 2 insertions(+), 2 deletions(-)
---
diff --git a/src/plugins/npm/npm_plugin.py b/src/plugins/npm/npm_plugin.py
index f797cb363..d99b104b4 100644
--- a/src/plugins/npm/npm_plugin.py
+++ b/src/plugins/npm/npm_plugin.py
@@ -167,13 +167,13 @@ class NPMBuildTargetProvider(Ide.Object, Ide.BuildTargetProvider):
         for name in package_json['scripts']:
             if is_ignored_script(name, package_json['scripts']):
                 continue
-            task.targets.append(NPMBuildTarget(name, context=self.get_context()))
+            task.targets.append(self.ensure_child_typed(NPMBuildTarget(name)))
 
         # if no start script is specified, but server.js exists,
         # we can still run "npm start"
         if 'start' not in package_json['scripts'] and \
             project_file.get_parent().get_child('server.js').query_exists(None):
-                task.targets.append(NPMBuildTarget('start', context=self.get_context()))
+                task.targets.append(self.ensure_child_typed(NPMBuildTarget('start')))
 
         task.return_boolean(True)
 


[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]