From b96a3aa401fdc50ad3b6d28ede6763dc79cfb587 Mon Sep 17 00:00:00 2001 From: Alexander Matyushentsev Date: Tue, 20 Aug 2019 09:16:10 -0700 Subject: [PATCH] Issue #2174 - Fix git repo url parsing on application list view (#2175) --- .../components/applications-list/applications-table.tsx | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/ui/src/app/applications/components/applications-list/applications-table.tsx b/ui/src/app/applications/components/applications-list/applications-table.tsx index 3713943d4c..0538d012d4 100644 --- a/ui/src/app/applications/components/applications-list/applications-table.tsx +++ b/ui/src/app/applications/components/applications-list/applications-table.tsx @@ -1,5 +1,6 @@ import { DropDownMenu, Tooltip } from 'argo-ui'; import * as React from 'react'; +const GitUrlParse = require('git-url-parse'); import { Cluster } from '../../../shared/components'; import { Consumer } from '../../../shared/context'; @@ -10,7 +11,7 @@ import * as AppUtils from '../utils'; require('./applications-table.scss'); function shortRepo(repo: string) { - const url = new URL(repo); + const url = GitUrlParse(repo); return {url.pathname.slice(1)}; }