fix(stream-proxy): 修复int类型比较错误,使用!=替代equals

This commit is contained in:
2026-02-25 14:35:48 +08:00
parent e06f851561
commit 152af7ec90

View File

@@ -241,7 +241,7 @@ public class StreamProxyServiceImpl implements IStreamProxyService {
!streamProxyInDb.getStream().equals(streamProxy.getStream())) {
StreamProxy duplicate = streamProxyMapper.selectOneByAppAndStream(
streamProxy.getApp(), streamProxy.getStream());
if (duplicate != null && !duplicate.getId().equals(streamProxy.getId())) {
if (duplicate != null && duplicate.getId() != streamProxy.getId()) {
throw new ControllerException(ErrorCode.ERROR100.getCode(),
"应用名 [" + streamProxy.getApp() + "] 下的流ID [" + streamProxy.getStream() + "] 已存在");
}