Load libraries from same protocl as page was served from
This commit is contained in:
parent
9f69fc4105
commit
3a738caa90
@ -6,7 +6,10 @@ loadLib = (libname) ->
|
||||
#Meteor.log.info "Failed to load library", param
|
||||
console.log "Failed to load library", param
|
||||
|
||||
Meteor.Loader.loadJs("https://#{window.location.hostname}/client/lib/#{libname}", successCallback, 10000).fail(retryMessageCallback)
|
||||
protocol = "http"
|
||||
if window.location.origin.match(/^https/)
|
||||
protocol = "https"
|
||||
Meteor.Loader.loadJs("#{protocol}://#{window.location.hostname}/client/lib/#{libname}", successCallback, 10000).fail(retryMessageCallback)
|
||||
|
||||
# These settings can just be stored locally in session, created at start up
|
||||
Meteor.startup ->
|
||||
|
Loading…
Reference in New Issue
Block a user