Commit 41d049c35c04404599a15c29e62a08d47f57e186

Authored by Justubborn
Committed by Gitee
1 parent 4f7cd65e

pref: 代码优化

yudao-module-infra/yudao-module-infra-biz/src/main/java/cn/iocoder/yudao/module/infra/service/codegen/CodegenServiceImpl.java
... ... @@ -206,7 +206,7 @@ public class CodegenServiceImpl implements CodegenService {
206 206 public Map<String, String> generationCodes(Long tableId) {
207 207 // 校验是否已经存在
208 208 CodegenTableDO table = codegenTableMapper.selectById(tableId);
209   - if (codegenTableMapper.selectById(tableId) == null) {
  209 + if (table == null) {
210 210 throw exception(CODEGEN_TABLE_NOT_EXISTS);
211 211 }
212 212 List<CodegenColumnDO> columns = codegenColumnMapper.selectListByTableId(tableId);
... ...