diff options
Diffstat (limited to 'app/assets')
6 files changed, 15 insertions, 10 deletions
diff --git a/app/assets/javascripts/clusters/components/applications.vue b/app/assets/javascripts/clusters/components/applications.vue index 704515cf70c..fe2ad562ad5 100644 --- a/app/assets/javascripts/clusters/components/applications.vue +++ b/app/assets/javascripts/clusters/components/applications.vue @@ -129,9 +129,6 @@ export default { crossplaneInstalled() { return this.applications.crossplane.status === APPLICATION_STATUS.INSTALLED; }, - enableClusterApplicationElasticStack() { - return gon.features && gon.features.enableClusterApplicationElasticStack; - }, ingressModSecurityDescription() { const escapedUrl = _.escape(this.ingressModSecurityHelpPath); @@ -655,7 +652,6 @@ Crossplane runs inside your Kubernetes cluster and supports secure connectivity </div> </application-row> <application-row - v-if="enableClusterApplicationElasticStack" id="elastic_stack" :logo-url="elasticStackLogo" :title="applications.elastic_stack.title" diff --git a/app/assets/javascripts/repository/components/breadcrumbs.vue b/app/assets/javascripts/repository/components/breadcrumbs.vue index f306910df05..9d6eda55c1e 100644 --- a/app/assets/javascripts/repository/components/breadcrumbs.vue +++ b/app/assets/javascripts/repository/components/breadcrumbs.vue @@ -107,10 +107,16 @@ export default { return acc.concat({ name, path, - to: `/-/tree/${this.ref}${path}`, + to: `/-/tree/${escape(this.ref)}${path}`, }); }, - [{ name: this.projectShortPath, path: '/', to: `/-/tree/${this.ref}/` }], + [ + { + name: this.projectShortPath, + path: '/', + to: `/-/tree/${escape(this.ref)}/`, + }, + ], ); }, canCreateMrFromFork() { diff --git a/app/assets/javascripts/repository/components/table/parent_row.vue b/app/assets/javascripts/repository/components/table/parent_row.vue index c919f2d42cb..096c25a693f 100644 --- a/app/assets/javascripts/repository/components/table/parent_row.vue +++ b/app/assets/javascripts/repository/components/table/parent_row.vue @@ -28,7 +28,7 @@ export default { return splitArray.join('/'); }, parentRoute() { - return { path: `/-/tree/${this.commitRef}/${this.parentPath}` }; + return { path: `/-/tree/${escape(this.commitRef)}/${this.parentPath}` }; }, }, methods: { diff --git a/app/assets/javascripts/repository/components/table/row.vue b/app/assets/javascripts/repository/components/table/row.vue index a0a9a5657a8..e7bbca957c1 100644 --- a/app/assets/javascripts/repository/components/table/row.vue +++ b/app/assets/javascripts/repository/components/table/row.vue @@ -90,7 +90,7 @@ export default { }, computed: { routerLinkTo() { - return this.isFolder ? { path: `/-/tree/${this.ref}/${this.path}` } : null; + return this.isFolder ? { path: `/-/tree/${escape(this.ref)}/${this.path}` } : null; }, iconName() { return `fa-${getIconName(this.type, this.path)}`; diff --git a/app/assets/javascripts/repository/log_tree.js b/app/assets/javascripts/repository/log_tree.js index 2a66659fecb..aefa4963d5f 100644 --- a/app/assets/javascripts/repository/log_tree.js +++ b/app/assets/javascripts/repository/log_tree.js @@ -27,7 +27,10 @@ export function fetchLogsTree(client, path, offset, resolver = null) { fetchpromise = axios .get( - `${gon.relative_url_root}/${projectPath}/-/refs/${ref}/logs_tree/${path.replace(/^\//, '')}`, + `${gon.relative_url_root}/${projectPath}/-/refs/${escape(ref)}/logs_tree/${path.replace( + /^\//, + '', + )}`, { params: { format: 'json', offset }, }, diff --git a/app/assets/javascripts/repository/router.js b/app/assets/javascripts/repository/router.js index fa544444be8..6c31c9bae82 100644 --- a/app/assets/javascripts/repository/router.js +++ b/app/assets/javascripts/repository/router.js @@ -12,7 +12,7 @@ export default function createRouter(base, baseRef) { base: joinPaths(gon.relative_url_root || '', base), routes: [ { - path: `/-/tree/${baseRef}(/.*)?`, + path: `/-/tree/${escape(baseRef)}(/.*)?`, name: 'treePath', component: TreePage, props: route => ({ |