From ce5ffa9fba0236b9b0739665b89bb60cd5357aa9 Mon Sep 17 00:00:00 2001 From: Shea Levy Date: Mon, 10 Aug 2015 13:47:39 -0400 Subject: [PATCH] Only pass the drv path if it is still valid --- src/lib/Hydra/Helper/AddBuilds.pm | 8 ++++++-- 1 file changed, 6 insertions(+), 2 deletions(-) diff --git a/src/lib/Hydra/Helper/AddBuilds.pm b/src/lib/Hydra/Helper/AddBuilds.pm index 416aa2b0..5d72e7a7 100644 --- a/src/lib/Hydra/Helper/AddBuilds.pm +++ b/src/lib/Hydra/Helper/AddBuilds.pm @@ -107,13 +107,17 @@ sub fetchInputBuild { my $mainOutput = getMainOutput($prevBuild); - return + my $result = { storePath => $mainOutput->path , id => $prevBuild->id , version => $version , outputName => $mainOutput->name - , drvPath => $prevBuild->drvPath }; + if (isValidPath($prevBuild->drvPath)) { + $input->{drvPath} = $prevBuild->drvPath; + } + + return $result; }