From 967a0d330f7f17c9d87a9f1594257acbe8422646 Mon Sep 17 00:00:00 2001 From: Jonathan Pearlin Date: Wed, 28 Sep 2011 10:13:04 -0400 Subject: [PATCH] Added regex to replace / with _ in resource name --- source/javascripts/swagger-service.js | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/source/javascripts/swagger-service.js b/source/javascripts/swagger-service.js index efc83e58..53b5b7fe 100644 --- a/source/javascripts/swagger-service.js +++ b/source/javascripts/swagger-service.js @@ -65,7 +65,7 @@ function SwaggerService(baseUrl, _apiKey, statusCallback) { this.path_xml = this.path.replace("{format}", "xml"); this.baseUrl = apiHost; //execluded 9 letters to remove .{format} from name - this.name = this.path.substr(1, this.path.length - formatString.length - 1); + this.name = this.path.substr(1, this.path.length - formatString.length - 1).replace(/\//g, "_"); this.apiList = Api.sub(); this.modelList = ApiModel.sub(); },