mirror of
https://github.com/jenkinsci/jenkins.git
synced 2026-11-16 13:32:24 +00:00
fixing NPE. getUrlName() contract allows returning null.
This commit is contained in:
1 parent
87f501ce53
commit
df259d7a89
1 file changed
+4
-1
@@ -454,9 +454,12 @@ public abstract class View extends AbstractModelObject implements AccessControll
|
||||
}
|
||||
|
||||
public Object getDynamic(String token) {
|
||||
for (Action a : getActions())
|
||||
for (Action a : getActions()) {
|
||||
String url = a.getUrlName();
|
||||
if (url==null) continue;
|
||||
if(a.getUrlName().equals(token))
|
||||
return a;
|
||||
}
|
||||
return null;
|
||||
}
|
||||
|
||||
|
||||
Reference in new issue
Block a user