PHP8.3 버전 warning 수정
This commit is contained in:
1 parent
ca078887a3
commit
d6d56e7938
6 files changed
+9
-6
No files matched your search
@@ -1,6 +1,9 @@
|
|||||||
<?php
|
<?php
|
||||||
|
|
||||||
const SERVICE_DB_SETTING_FILE = "./../../server/setup/service_db_setting.php";
|
const SERVICE_DB_SETTING_FILE = __DIR__ . "/../../server/setup/service_db_setting.php";
|
||||||
|
|
||||||
|
// PHP 8.1+ 는 mysqli 오류 시 예외를 던진다. 기존처럼 반환값으로 처리하기 위해 끈다.
|
||||||
|
mysqli_report(MYSQLI_REPORT_OFF);
|
||||||
$has_file = file_exists(SERVICE_DB_SETTING_FILE);
|
$has_file = file_exists(SERVICE_DB_SETTING_FILE);
|
||||||
if ($has_file) {
|
if ($has_file) {
|
||||||
include(SERVICE_DB_SETTING_FILE);
|
include(SERVICE_DB_SETTING_FILE);
|
||||||
|
|||||||
@@ -18,7 +18,7 @@ if($maestroID === null) {
|
|||||||
|
|
||||||
$loginData = login($maestroName, $password);
|
$loginData = login($maestroName, $password);
|
||||||
|
|
||||||
$date = new DateTime($loginData["availableActivateDateTime"]);
|
$date = new DateTime($loginData["availableActivateDateTime"] ?? "now");
|
||||||
$now = new DateTime();
|
$now = new DateTime();
|
||||||
if($loginData === null) {
|
if($loginData === null) {
|
||||||
set_error_code("no_data");
|
set_error_code("no_data");
|
||||||
|
|||||||
@@ -40,7 +40,7 @@ if($activateStatus == 0) {
|
|||||||
exit;
|
exit;
|
||||||
}
|
}
|
||||||
|
|
||||||
$date = new DateTime($maestroInfo["availableActivateDateTime"]);
|
$date = new DateTime($maestroInfo["availableActivateDateTime"] ?? "now");
|
||||||
$now = new DateTime();
|
$now = new DateTime();
|
||||||
if($maestroInfo["activateStatus"] === 1 && $date < $now) {
|
if($maestroInfo["activateStatus"] === 1 && $date < $now) {
|
||||||
set_error_message("마에스트로 계정의 유효기간이 지났습니다.\n(만료일 : ".$date->format("Y-m-d").")\n선생님께 문의하세요.");
|
set_error_message("마에스트로 계정의 유효기간이 지났습니다.\n(만료일 : ".$date->format("Y-m-d").")\n선생님께 문의하세요.");
|
||||||
|
|||||||
@@ -8,7 +8,7 @@ include "./../setup/connect_db.php";
|
|||||||
$maestro_id = (int)$_POST["MaestroID"];
|
$maestro_id = (int)$_POST["MaestroID"];
|
||||||
$start_date = $_POST["StartDate"];
|
$start_date = $_POST["StartDate"];
|
||||||
$end_date = $_POST["EndDate"];
|
$end_date = $_POST["EndDate"];
|
||||||
$player_name = trim($_POST["PlayerNameList"]);
|
$player_name = trim($_POST["PlayerNameList"] ?? "");
|
||||||
$app_id = (int)$_POST["AppID"];
|
$app_id = (int)$_POST["AppID"];
|
||||||
$limit_count = (int)$_POST["LimitCount"];
|
$limit_count = (int)$_POST["LimitCount"];
|
||||||
|
|
||||||
|
|||||||
@@ -8,7 +8,7 @@ include "./../setup/connect_db.php";
|
|||||||
$maestro_id = (int)$_POST["MaestroID"];
|
$maestro_id = (int)$_POST["MaestroID"];
|
||||||
$start_date = $_POST["StartDate"];
|
$start_date = $_POST["StartDate"];
|
||||||
$end_date = $_POST["EndDate"];
|
$end_date = $_POST["EndDate"];
|
||||||
$player_name = trim($_POST["PlayerNameList"]);
|
$player_name = trim($_POST["PlayerNameList"] ?? "");
|
||||||
$app_id = (int)$_POST["AppID"];
|
$app_id = (int)$_POST["AppID"];
|
||||||
$limit_count = (int)$_POST["LimitCount"];
|
$limit_count = (int)$_POST["LimitCount"];
|
||||||
|
|
||||||
|
|||||||
@@ -8,7 +8,7 @@ include "./../setup/connect_db.php";
|
|||||||
$maestro_id = (int)$_POST["MaestroID"];
|
$maestro_id = (int)$_POST["MaestroID"];
|
||||||
$start_date = $_POST["StartDate"];
|
$start_date = $_POST["StartDate"];
|
||||||
$end_date = $_POST["EndDate"];
|
$end_date = $_POST["EndDate"];
|
||||||
$player_name = trim($_POST["PlayerNameList"]);
|
$player_name = trim($_POST["PlayerNameList"] ?? "");
|
||||||
$app_id = (int)$_POST["AppID"];
|
$app_id = (int)$_POST["AppID"];
|
||||||
$limit_count = (int)$_POST["LimitCount"];
|
$limit_count = (int)$_POST["LimitCount"];
|
||||||
|
|
||||||
|
|||||||
Reference in new issue
Block a user