修改swagger解析报错,白名单域名默认为不限制

This commit is contained in:
暮光:城中城
2019-06-24 22:43:21 +08:00
parent f83c27882f
commit 29586f35d7
3 changed files with 130 additions and 130 deletions

View File

@@ -41,7 +41,7 @@ zyplayer:
swagger: swagger:
proxy-request: proxy-request:
# 允许代理请求的域名,正则表达式,多个使用 ; 分割,必须设置,防止通过代理接口访问到内部资源,实在觉得没必要可设置为:.+ # 允许代理请求的域名,正则表达式,多个使用 ; 分割,必须设置,防止通过代理接口访问到内部资源,实在觉得没必要可设置为:.+
white-domain: \S+\.zyplayer\.com;127.0.1:8080;\S+\.xiaominfo\.com; white-domain: .+
# ------dubbo相关配置------ # ------dubbo相关配置------
dubbo: dubbo:
# 优先使用zookeeper未配置时找nacos的配置 # 优先使用zookeeper未配置时找nacos的配置

View File

@@ -61,7 +61,7 @@ function createTreeViewByTag(json, keywords) {
* @returns * @returns
*/ */
function setRequestMethodForTag(domain, source, pathObj, url, method) { function setRequestMethodForTag(domain, source, pathObj, url, method) {
if (isEmpty(source[method])) { if (isEmpty(source[method]) || !source[method].tags) {
return; return;
} }
source[method].tags.forEach(function(val, index) { source[method].tags.forEach(function(val, index) {

View File

@@ -62,7 +62,7 @@ function createTreeViewByTag(json, keywords) {
* @returns * @returns
*/ */
function setRequestMethodForTag(rewriteDomainUrl, domain, source, pathObj, url, method) { function setRequestMethodForTag(rewriteDomainUrl, domain, source, pathObj, url, method) {
if (isEmpty(source[method])) { if (isEmpty(source[method]) || !source[method].tags) {
return; return;
} }
source[method].tags.forEach(function(val, index) { source[method].tags.forEach(function(val, index) {