Forum Discussion
Anonymous
11 months agoIt will fail if the property doesn’t exist. You can specify a value to use if the property doesn’t exist.
The groovy way is String user = hostProps.get("scc.user") ?: “unknownuser”
The method also supposedly also can do that like this: String user = hostProps.get("scc.user", “unknown user”)
Related Content
- 5 months ago