Details
-
Type:
Improvement
-
Status: Done/Fixed
-
Priority:
Trivial
-
Resolution: Fixed/Completed
-
Affects Version/s: 4.6.10
-
Fix Version/s: 4.7
-
Component/s: Drupal Integration Modules
-
Labels:
-
Documentation Required?:Developer Doc
-
Funding Source:Contributed Code
Description
When calling civicrm-sql-conf, the configuration is outputted as string, which isn't useful when you want to use the result in another script.
See below what the difference is.
command:
drush php-eval '$result = drush_invoke_process("@self", "civicrm-sql-conf", array(), array(), array('integrate' => FALSE)); var_dump($result["output"]); var_dump($result["object"]);'
before patch:
string(167) "Array
(
[driver] => mysql
[username] => username
[password] => password
[host] => 127.0.0.1
[port] =>
[database] => database
)
"
array(0) {
}
after patch
string(167) "Array
(
[driver] => mysql
[username] => username
[password] => password
[host] => 127.0.0.1
[port] =>
[database] => database
)
"
array(6) {
'driver' =>
string(5) "mysql"
'username' =>
string(4) "username"
'password' =>
string(12) "password"
'host' =>
string(9) "127.0.0.1"
'port' =>
string(0) ""
'database' =>
string(22) "database"
}
The PR will fix this.