Skip to content
Snippets Groups Projects
Commit 034447da authored by Jean-Laurent DUZANT's avatar Jean-Laurent DUZANT Committed by Guillaume Heurtier
Browse files

FEAT #23832 TIME 0:05 replace config.xml to config.json

parent 50f7f12c
No related branches found
No related tags found
No related merge requests found
/.angular/cache /.angular/cache
config/config.xml config/config.json
.vscode/ .vscode/
.*.swp .*.swp
.phplint-cache .phplint-cache
......
...@@ -36,7 +36,7 @@ $app->add(function (\Slim\Psr7\Request $request, \Psr\Http\Server\RequestHandler ...@@ -36,7 +36,7 @@ $app->add(function (\Slim\Psr7\Request $request, \Psr\Http\Server\RequestHandler
$response = new \SrcCore\http\Response(); $response = new \SrcCore\http\Response();
$configPath = \SrcCore\models\CoreConfigModel::getConfigPath(); $configPath = \SrcCore\models\CoreConfigModel::getConfigPath();
if (!is_file($configPath . '/config.xml')) { if (!is_file($configPath . '/config.json')) {
return $response->withStatus(400)->withJson(['errors' => 'Configuration file is missing']); return $response->withStatus(400)->withJson(['errors' => 'Configuration file is missing']);
} }
......
...@@ -10,7 +10,7 @@ ...@@ -10,7 +10,7 @@
require_once 'vendor/autoload.php'; require_once 'vendor/autoload.php';
$id = 1; $id = 1;
if (empty($_SERVER['CONFIG_DIR']) && is_file("{$_SERVER['PWD']}/config/config.xml")) { if (empty($_SERVER['CONFIG_DIR']) && is_file("{$_SERVER['PWD']}/config/config.json")) {
$_SERVER['CONFIG_DIR'] = "{$_SERVER['PWD']}/config/"; $_SERVER['CONFIG_DIR'] = "{$_SERVER['PWD']}/config/";
} }
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment