Fix for #1252, check for http protocol before setting validator url
This commit is contained in:
@@ -68,9 +68,11 @@ SwaggerUi.Views.MainView = Backbone.View.extend({
|
||||
} else {
|
||||
|
||||
// Default validator
|
||||
if(window.location.protocol.startsWith('http')) {
|
||||
this.model.validatorUrl = window.location.protocol + '//online.swagger.io/validator';
|
||||
}
|
||||
}
|
||||
}
|
||||
},
|
||||
|
||||
render: function(){
|
||||
|
||||
Reference in New Issue
Block a user