Fixes regression for empty org folder for github
* Fixes regression where loadPipeline() didn't get called for empty repo
for org folders
* ensure scmId is propagated to loadPipeline()
@@ -119,7 +119,9 @@ class PipelineLoader extends React.Component {
componentWillMount() {
pipelineStore.setPipeline(null); // reset any previous loaded pipeline
const { organization, pipeline } = this.props.params;
- let href = Paths.rest.pipeline(organization, pipeline);
+ const split = pipeline.split('/');
+ const team = split[0];
+ let href = Paths.rest.pipeline(organization, team);
pipelineService.fetchPipeline(href, { useCache: true })
.then(pipeline => {
if(pipeline.scmSource && pipeline.scmSource.id) {
