diff --git a/app/components/endpoints/endpointsController.js b/app/components/endpoints/endpointsController.js index 9a761a164..01e9670e5 100644 --- a/app/components/endpoints/endpointsController.js +++ b/app/components/endpoints/endpointsController.js @@ -1,6 +1,6 @@ angular.module('endpoints', []) -.controller('EndpointsController', ['$scope', '$state', 'EndpointService', 'EndpointProvider', 'Notifications', 'Pagination', -function ($scope, $state, EndpointService, EndpointProvider, Notifications, Pagination) { +.controller('EndpointsController', ['$scope', '$state', '$filter', 'EndpointService', 'EndpointProvider', 'Notifications', 'Pagination', +function ($scope, $state, $filter, EndpointService, EndpointProvider, Notifications, Pagination) { $scope.state = { uploadInProgress: false, selectedItemCount: 0, @@ -44,7 +44,7 @@ function ($scope, $state, EndpointService, EndpointProvider, Notifications, Pagi $scope.addEndpoint = function() { var name = $scope.formValues.Name; - var URL = $scope.formValues.URL; + var URL = $filter('stripprotocol')($scope.formValues.URL); var PublicURL = $scope.formValues.PublicURL; if (PublicURL === '') { PublicURL = URL.split(':')[0];