mirror of
https://gitlab.linphone.org/BC/public/flexisip-account-manager.git
synced 2026-01-17 10:08:05 +00:00
add default value to config params
This commit is contained in:
parent
b30d1a09f5
commit
a0b6b2db8b
3 changed files with 6 additions and 2 deletions
|
|
@ -8,7 +8,7 @@
|
|||
#%define _datadir %{_datarootdir}
|
||||
#%define _docdir %{_datadir}/doc
|
||||
|
||||
%define build_number 17
|
||||
%define build_number 18
|
||||
%define var_dir /var/opt/belledonne-communications
|
||||
%define opt_dir /opt/belledonne-communications/share/flexisip-account-manager
|
||||
%define env_file "$RPM_BUILD_ROOT/etc/flexisip-account-manager/flexiapi.env"
|
||||
|
|
|
|||
|
|
@ -29,7 +29,7 @@ class Database
|
|||
$this->conn = null;
|
||||
|
||||
try {
|
||||
if(!empty(DB_ENABLE_SSL) && !empty(ROOT_CA_PATH)){
|
||||
if(!empty(get_config_value("DB_ENABLE_SSL","")) && !empty(get_config_value("ROOT_CA_PATH",""))){
|
||||
if(!file_exists (ROOT_CA_PATH)){
|
||||
Logger::getInstance()->error("MySQL connection error: the provided ROOT_CA_PATH does not exists!");
|
||||
}
|
||||
|
|
|
|||
|
|
@ -188,3 +188,7 @@ function time_elapsed_as_string($secs)
|
|||
|
||||
return join(' ', $ret);
|
||||
}
|
||||
function get_config_value($param_name, $default_value) {
|
||||
return defined($param_name) ? constant($param_name) : $default_value;
|
||||
}
|
||||
|
||||
|
|
|
|||
Loading…
Add table
Reference in a new issue