implement usage of __DIR__ to fix references on include

This commit is contained in:
2018-04-24 13:35:33 +02:00
parent 0c1141dbb9
commit d597a54353
14 changed files with 36 additions and 36 deletions

View File

@@ -44,14 +44,14 @@ try {
throw new Exception('"new_password" is not defined');
}
require_once("../helpers.php");
require_once(__DIR__ . "/../helpers.php");
$localpart = stripLocalpart($input["auth"]["user"]);
if (empty($localpart)) {
throw new Exception("localpart cannot be identified");
}
require_once("../database.php");
require_once(__DIR__ . "/../database.php");
if (!$mx_db->updatePassword(
$localpart, $input["auth"]["password"], $input["new_password"]
)) {