diff --git a/client/src/app/deploy/sections/automatic/automatic.component.ts b/client/src/app/deploy/sections/automatic/automatic.component.ts index d741ff1..3749cfb 100644 --- a/client/src/app/deploy/sections/automatic/automatic.component.ts +++ b/client/src/app/deploy/sections/automatic/automatic.component.ts @@ -345,14 +345,17 @@ export class AutomaticComponent implements OnInit { * This is needed to ensure that the DC will use the same compute context `makedata` service used to run against. */ public async updateIndexHtmlComputeContext() { + const filenamePath = location.search.split('/').pop() + const filename = filenamePath?.includes('.') ? filenamePath : 'DataController.html' + const indexHtmlContent = await this.sasService.getFileContent( `${this.appLoc}/services`, - 'DataController.html' + filename ) if (!indexHtmlContent) { this.loggerService.error( - `Failed to get DataController.html at ${this.appLoc}/services` + `Failed to get ${filename} at ${this.appLoc}/services` ) return } @@ -376,7 +379,7 @@ export class AutomaticComponent implements OnInit { await this.sasService .updateFileContent( `${this.appLoc}/services`, - 'DataController.html', + filename, updatedContent ) .catch((err: any) => {