We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent eb50c5c commit 5029e13Copy full SHA for 5029e13
.github/workflows/deploy-cors-proxy.yml
@@ -73,7 +73,13 @@ jobs:
73
if [[ -n "${CUSTOM_SUPPORTED_ORIGINS_NEWLINE_SEPARATED}" ]]; then
74
CUSTOM_ORIGINS_PHP="<?php define('PLAYGROUND_CORS_PROXY_SUPPORTED_ORIGINS', array("
75
76
- echo "$CUSTOM_SUPPORTED_ORIGINS_NEWLINE_SEPARATED" | while read -r origin; do
+ for origin in $CUSTOM_SUPPORTED_ORIGINS_NEWLINE_SEPARATED; do
77
+ # Remove leading and trailing whitespace
78
+ # NOTE: IIUC, this should already be happening as part of
79
+ # string splitting, but it does not appear to be.
80
+ origin="${origin##*([[:space:]])}"
81
+ origin="${origin%%*([[:space:]])}"
82
+
83
if ! [[
84
$origin =~ ^https?:\/\/(?:[a-zA-Z0-9-]+\.)*[a-zA-Z0-9-]+\.[a-zA-Z]{2,}(?::\d{1,5})?$
85
]]; then
0 commit comments