Update TencentSCF_file.php

This commit is contained in:
qkqpttgf 2020-08-06 11:34:38 +08:00 committed by GitHub
parent c653abf457
commit 08c790690d
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
1 changed files with 2 additions and 1 deletions

View File

@ -365,7 +365,8 @@ function updateEnvironment($Envs, $function_name, $Region, $Namespace, $SecretId
function SetbaseConfig($Envs, $function_name, $Region, $Namespace, $SecretId, $SecretKey)
{
if ($Envs['ONEMANAGER_CONFIG_SAVE'] != 'file') $Envs = Array( 'ONEMANAGER_CONFIG_SAVE' => '' );
if ($Envs['ONEMANAGER_CONFIG_SAVE'] == 'file') $Envs = Array( 'ONEMANAGER_CONFIG_SAVE' => 'file' );
else $Envs = Array( 'ONEMANAGER_CONFIG_SAVE' => '' );
$tmp = json_decode(getfunctioninfo($function_name, $Region, $Namespace, $SecretId, $SecretKey),true)['Response']['Environment']['Variables'];
foreach ($tmp as $tmp1) {
$tmp_env[$tmp1['Key']] = $tmp1['Value'];