Skip to content

Commit

Permalink
min_wr_num Undefined 경고문이 나올수 있는 코드 수정
Browse files Browse the repository at this point in the history
  • Loading branch information
thisgun committed Apr 17, 2023
1 parent 4204f79 commit 8ecc5ba
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion lib/common.lib.php
Original file line number Diff line number Diff line change
Expand Up @@ -768,7 +768,7 @@ function get_next_num($table)
$sql = " select min(wr_num) as min_wr_num from $table ";
$row = sql_fetch($sql);
// 가장 작은 번호에 1을 빼서 넘겨줌
return (int)($row['min_wr_num'] - 1);
return isset($row['min_wr_num']) ? (int)($row['min_wr_num'] - 1) : -1;
}


Expand Down

0 comments on commit 8ecc5ba

Please sign in to comment.