Skip to content

Commit 4b1351d

Browse files
More FileLike
1 parent e8be0dc commit 4b1351d

File tree

1 file changed

+7
-16
lines changed

1 file changed

+7
-16
lines changed

genotyping/src/org/labkey/genotyping/GenotypingController.java

Lines changed: 7 additions & 16 deletions
Original file line numberDiff line numberDiff line change
@@ -1395,24 +1395,15 @@ public boolean handlePost(PipelinePathForm form, BindException errors) throws IO
13951395
{
13961396
Container container = getContainer();
13971397
// Manual upload of genotyping analysis; pipeline provider posts to this action with matches file.
1398-
Path singleFile = form.getValidatedSinglePath(container);
1398+
FileLike singleFile = form.getValidatedSingleFile(container);
1399+
FileLike analysisDir = singleFile.getParent();
13991400

1400-
if (form.getPipeRoot(container).getRootFileLike().isDescendant(singleFile.toUri()))
1401-
{
1402-
1403-
FileLike matches = form.getPipeRoot(container).resolvePathToFileLike(singleFile.toString());
1404-
FileLike analysisDir = matches.getParent();
1401+
// Load properties to determine the run.
1402+
Properties props = GenotypingManager.get().readProperties(analysisDir);
1403+
int analysisId = Integer.parseInt((String) props.get("analysis"));
1404+
importAnalysis(analysisId, analysisDir, getUser());
14051405

1406-
// Load properties to determine the run.
1407-
Properties props = GenotypingManager.get().readProperties(analysisDir);
1408-
int analysisId = Integer.parseInt((String) props.get("analysis"));
1409-
importAnalysis(analysisId, analysisDir, getUser());
1410-
1411-
return true;
1412-
}
1413-
1414-
errors.reject(ERROR_MSG, "File was not found under the pipeline root");
1415-
return false;
1406+
return true;
14161407
}
14171408

14181409
@Override

0 commit comments

Comments
 (0)