diff --git a/packages/gapic-node-templating/src/get-bootstrap-template-vars.ts b/packages/gapic-node-templating/src/get-bootstrap-template-vars.ts index 287ef2d7be5..5d532a34068 100644 --- a/packages/gapic-node-templating/src/get-bootstrap-template-vars.ts +++ b/packages/gapic-node-templating/src/get-bootstrap-template-vars.ts @@ -129,7 +129,7 @@ export function getApiPath(apiId: string) { } export function getApiPathWithDashes(apiId: string) { - return apiId.replace(/\.v.*/, '').replace(/\./g, '-'); + return apiId.replace(/\.v[0-9].*/, '').replace(/\./g, '-'); } export function getVersion(apiId: string) {