From 15d689b0c26070ff1cb6ee41cc58ba5b8483aa1c Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Se=CC=81rgio=20Ramos?= Date: Wed, 28 Jun 2017 11:00:07 +0100 Subject: [PATCH] feat(cp-frontend): remove leading '/' from services url --- packages/cp-frontend/src/containers/services/list.js | 2 +- packages/cp-frontend/src/containers/services/topology.js | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/packages/cp-frontend/src/containers/services/list.js b/packages/cp-frontend/src/containers/services/list.js index 6f957aa4..690a6974 100644 --- a/packages/cp-frontend/src/containers/services/list.js +++ b/packages/cp-frontend/src/containers/services/list.js @@ -128,7 +128,7 @@ class ServiceList extends Component { const mapStateToProps = (state, ownProps) => ({ servicesQuickActions: state.ui.services.quickActions, - url: ownProps.match.url + url: ownProps.match.url.replace(/\/$/, '') }); const mapDispatchToProps = dispatch => ({ diff --git a/packages/cp-frontend/src/containers/services/topology.js b/packages/cp-frontend/src/containers/services/topology.js index 12915b82..9c5f96a5 100644 --- a/packages/cp-frontend/src/containers/services/topology.js +++ b/packages/cp-frontend/src/containers/services/topology.js @@ -102,7 +102,7 @@ const ServicesTopology = ({ const mapStateToProps = (state, ownProps) => ({ servicesQuickActions: state.ui.services.quickActions, - url: ownProps.match.url, + url: ownProps.match.url.replace(/\/$/, ''), push: ownProps.history.push });