You are viewing a plain text version of this content. The canonical link for it is here.
Posted to notifications@skywalking.apache.org by wu...@apache.org on 2019/04/28 09:40:28 UTC

[skywalking] branch alarm-query updated: Fix NPE.

This is an automated email from the ASF dual-hosted git repository.

wusheng pushed a commit to branch alarm-query
in repository https://gitbox.apache.org/repos/asf/skywalking.git


The following commit(s) were added to refs/heads/alarm-query by this push:
     new 2dfc3dd  Fix NPE.
2dfc3dd is described below

commit 2dfc3dd2d836e4a3b43c752ad060162197c29638
Author: Wu Sheng <wu...@foxmail.com>
AuthorDate: Sun Apr 28 17:40:20 2019 +0800

    Fix NPE.
---
 .../org/apache/skywalking/oap/query/graphql/resolver/AlarmQuery.java    | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/oap-server/server-query-plugin/query-graphql-plugin/src/main/java/org/apache/skywalking/oap/query/graphql/resolver/AlarmQuery.java b/oap-server/server-query-plugin/query-graphql-plugin/src/main/java/org/apache/skywalking/oap/query/graphql/resolver/AlarmQuery.java
index 91689d1..acbec88 100644
--- a/oap-server/server-query-plugin/query-graphql-plugin/src/main/java/org/apache/skywalking/oap/query/graphql/resolver/AlarmQuery.java
+++ b/oap-server/server-query-plugin/query-graphql-plugin/src/main/java/org/apache/skywalking/oap/query/graphql/resolver/AlarmQuery.java
@@ -55,7 +55,7 @@ public class AlarmQuery implements GraphQLQueryResolver {
         long endTimeBucket = DurationUtils.INSTANCE.endTimeDurationToSecondTimeBucket(duration.getStep(), duration.getEnd());
 
         Integer scopeId = null;
-        if (scope == null) {
+        if (scope != null) {
             scopeId = scope.getScopeId();
         }