fix(media-manager): correct Google Picker origin for Apps Script IFRAME environment

This commit is contained in:
Ben Miller
2025-12-29 21:17:12 -07:00
parent f6831cdc8f
commit bade8a3020

View File

@ -1506,7 +1506,7 @@
builder.addView(view)
.setOAuthToken(config.token)
.setDeveloperKey(config.apiKey)
.setOrigin(window.location.protocol + '//' + window.location.host)
.setOrigin(google.script.host.origin || (window.location.protocol + '//' + window.location.host))
.setCallback(data => {
if (data.action == google.picker.Action.PICKED) {
const doc = data.docs[0];