diff --git a/core/src/main/java/com/megaease/easeagent/core/plugin/interceptor/InterceptorPluginDecorator.java b/core/src/main/java/com/megaease/easeagent/core/plugin/interceptor/InterceptorPluginDecorator.java index cbcd14ee..3a1f71d4 100644 --- a/core/src/main/java/com/megaease/easeagent/core/plugin/interceptor/InterceptorPluginDecorator.java +++ b/core/src/main/java/com/megaease/easeagent/core/plugin/interceptor/InterceptorPluginDecorator.java @@ -64,16 +64,18 @@ public void before(MethodInfo methodInfo, Context context) { public void after(MethodInfo methodInfo, Context context) { IPluginConfig cfg = context.getConfig(); InitializeContext innerContext = (InitializeContext) context; - - if (cfg == null || cfg.enabled() || cfg instanceof NoOpIPluginConfig) { - try { - this.interceptor.after(methodInfo, context); - } finally { - innerContext.popToBound(); - innerContext.popRetBound(); + try { + if (cfg == null || cfg.enabled() || cfg instanceof NoOpIPluginConfig) { + try { + this.interceptor.after(methodInfo, context); + } finally { + innerContext.popToBound(); + innerContext.popRetBound(); + } } + } finally { + innerContext.popConfig(); } - innerContext.popConfig(); } @Override