Skip to content

Commit

Permalink
Update repository param name
Browse files Browse the repository at this point in the history
Signed-off-by: Simeon Widdis <sawiddis@amazon.com>
  • Loading branch information
Swiddis committed Nov 13, 2023
1 parent 3f71962 commit 93e8210
Showing 1 changed file with 5 additions and 5 deletions.
10 changes: 5 additions & 5 deletions server/adaptors/integrations/repository/repository.ts
Original file line number Diff line number Diff line change
Expand Up @@ -31,15 +31,15 @@ export class TemplateManager {
return integrations.filter((x) => x !== null) as IntegrationReader[];
}

async getIntegration(name: string): Promise<IntegrationReader | null> {
if ((await this.reader.getDirectoryType(name)) !== 'integration') {
console.error(`Requested integration '${name}' does not exist`);
async getIntegration(integPath: string): Promise<IntegrationReader | null> {
if ((await this.reader.getDirectoryType(integPath)) !== 'integration') {
console.error(`Requested integration '${integPath}' does not exist`);
return null;
}
const integ = new IntegrationReader(name, this.reader.join(name));
const integ = new IntegrationReader(integPath, this.reader.join(integPath));
const checkResult = await integ.getConfig();
if (!checkResult.ok) {
console.error(`Integration '${name}' is invalid:`, checkResult.error);
console.error(`Integration '${integPath}' is invalid:`, checkResult.error);
return null;
}
return integ;
Expand Down

0 comments on commit 93e8210

Please sign in to comment.