I'm getting different results from CLI and browser for a command, I don't know why. It is a security feature of psysh or sliver? [edited] means a string was there that for security reasons has been edited out.
From CLI I run
$Mautic = new Mautic();
=> Mautic {#197
+class: null,
+"_contextapi": [],
}
$Mautic->getSettings();
=> [
"baseUrl" => "[edited]",
"version" => "BasicAuth",
"clientKey" => "[edited]",
"clientSecret" => "[edited]",
"callback" => false,
"access_token" => "[edited]",
"expires" => "[edited]",
"token_type" => "[edited]",
"refresh_token" => "[edited]",
"userName" => null,
"password" => null,
]
From browser the same code
$Mautic = new Mautic();
$s=$Mautic->getSettings();
var_dump($s);
die();
returns
array(11) {
["baseUrl"]=>
string(29) "[edited]"
["version"]=>
string(9) "[edited]"
["clientKey"]=>
string(52) "[edited]"
["clientSecret"]=>
string(50) "[edited]"
["callback"]=>
string(41) "[edited]"
["access_token"]=>
string(86) "[edited]"
["expires"]=>
string(10) "[edited]"
["token_type"]=>
string(6) "[edited]"
["refresh_token"]=>
string(86) "[edited]"
["userName"]=>
string(9) "[edited]"
["password"]=>
string(10) "[edited]"
}
note that callback, userName and password bear different values. I went crazy tried to find the bug in the code, found out that it was a bug in the CLI. The settings you see are simply values recorded in the SilverStripe 3.6.5 SiteConfig. I wonder if there's a problem with the sliver bootstrap.
I'm getting different results from CLI and browser for a command, I don't know why. It is a security feature of psysh or sliver? [edited] means a string was there that for security reasons has been edited out.
From CLI I run
From browser the same code
returns
note that callback, userName and password bear different values. I went crazy tried to find the bug in the code, found out that it was a bug in the CLI. The settings you see are simply values recorded in the SilverStripe 3.6.5 SiteConfig. I wonder if there's a problem with the sliver bootstrap.