提交 bac28a5a 编写于 作者: K Kohsuke Kawaguchi

improved CLI usage compatibility

上级 ccf3351b
......@@ -103,7 +103,8 @@ public class AnnotatedLargeText<T> extends LargeText {
* and use this request attribute to differentiate.
*/
private boolean isHtml() {
return Stapler.getCurrentRequest().getAttribute("html")!=null;
StaplerRequest req = Stapler.getCurrentRequest();
return req!=null && req.getAttribute("html")!=null;
}
@Override
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册