File tree Expand file tree Collapse file tree 3 files changed +7
-8
lines changed
Expand file tree Collapse file tree 3 files changed +7
-8
lines changed Original file line number Diff line number Diff line change 11// Config specific to local development
2- import { addonsServerDevCDN , analyticsHost , apiDevHost } from './lib/shared' ;
2+ import { baseUrlDev , analyticsHost , apiDevHost } from './lib/shared' ;
33
44const webpackServerHost = process . env . WEBPACK_SERVER_HOST || '127.0.0.1' ;
55const webpackServerPort = 3001 ;
@@ -24,7 +24,7 @@ module.exports = {
2424 trackingEnabled : false ,
2525 loggingLevel : 'debug' ,
2626
27- amoCDN : addonsServerDevCDN ,
27+ amoCDN : baseUrlDev ,
2828
2929 isDeployed : false ,
3030 isDevelopment : true ,
@@ -47,7 +47,7 @@ module.exports = {
4747 directives : {
4848 connectSrc : [
4949 "'self'" ,
50- addonsServerDevCDN ,
50+ baseUrlDev ,
5151 analyticsHost ,
5252 apiDevHost ,
5353 webpackDevServer ,
@@ -60,14 +60,14 @@ module.exports = {
6060 imgSrc : [
6161 "'self'" ,
6262 'data:' ,
63- addonsServerDevCDN ,
63+ baseUrlDev ,
6464 webpackDevServer ,
6565 ] ,
6666 scriptSrc : [
6767 "'self'" ,
6868 // webpack injects inline JS
6969 "'unsafe-inline'" ,
70- addonsServerDevCDN ,
70+ baseUrlDev ,
7171 webpackDevServer ,
7272 `${ analyticsHost } /analytics.js` ,
7373 ] ,
Original file line number Diff line number Diff line change 7070 "amo:dev" : {
7171 "command" : " better-npm-run start-dev-proxy" ,
7272 "env" : {
73- "AMO_CDN" : " https://addons-dev-cdn.allizom.org" ,
7473 "PROXY_API_HOST" : " https://addons-dev.allizom.org"
7574 }
7675 },
339338 "maxSize" : " 36 kB"
340339 }
341340 ]
342- }
341+ }
Original file line number Diff line number Diff line change @@ -258,7 +258,7 @@ export function isAddonAuthor({
258258export function isAllowedOrigin (
259259 urlString : string ,
260260 {
261- allowedOrigins = [ config . get ( 'amoCDN' ) ] ,
261+ allowedOrigins = [ config . get ( 'amoCDN' ) , config . get ( 'baseURL' ) ] ,
262262 } : { | allowedOrigins ?: Array < string > | } = { } ,
263263) : boolean {
264264 let parsedURL ;
You can’t perform that action at this time.
0 commit comments