You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@kylin.apache.org by sh...@apache.org on 2018/09/25 00:23:43 UTC
[kylin] branch master updated: KYLIN-3582 String compare should use
equals method
This is an automated email from the ASF dual-hosted git repository.
shaofengshi pushed a commit to branch master
in repository https://gitbox.apache.org/repos/asf/kylin.git
The following commit(s) were added to refs/heads/master by this push:
new d8c2a28 KYLIN-3582 String compare should use equals method
d8c2a28 is described below
commit d8c2a282930adb0d93e827ed014fbe7ceda69c09
Author: hit-lacus <hi...@126.com>
AuthorDate: Mon Sep 24 23:18:54 2018 +0800
KYLIN-3582 String compare should use equals method
---
.../src/main/java/org/apache/kylin/metrics/lib/impl/RecordEvent.java | 3 +--
1 file changed, 1 insertion(+), 2 deletions(-)
diff --git a/core-metrics/src/main/java/org/apache/kylin/metrics/lib/impl/RecordEvent.java b/core-metrics/src/main/java/org/apache/kylin/metrics/lib/impl/RecordEvent.java
index 894386e..6452d78 100644
--- a/core-metrics/src/main/java/org/apache/kylin/metrics/lib/impl/RecordEvent.java
+++ b/core-metrics/src/main/java/org/apache/kylin/metrics/lib/impl/RecordEvent.java
@@ -262,11 +262,10 @@ public class RecordEvent implements Record, Map<String, Object>, Serializable {
public RecordReserveKeyEnum getByKey(String key) {
for (RecordReserveKeyEnum reserveKey : RecordReserveKeyEnum.values()) {
- if (reserveKey.reserveKey == key) {
+ if (reserveKey.reserveKey.equals(key)) {
return reserveKey;
}
}
-
return null;
}
}