Fix default value check 22/88922/2
authorMagic_J <panda.magic.j@gmail.com>
Mon, 9 Apr 2018 06:17:44 +0000 (14:17 +0800)
committerRobert Varga <nite@hq.sk>
Tue, 7 Apr 2020 03:34:50 +0000 (03:34 +0000)
commita002f5a401b6528f77f3e67b759117e8fc33231b
tree0041ba66f1e222d9e5b0a27b9da03aec9c18e590
parentc20e3a3b4273f395094369df09900b066d7ff5a9
Fix default value check

TypeDefinition.getDefaultValue() is returning an optional, which
results in it always being non-null. Fix the check for nullness
and make sure we use the correct value.

Change-Id: Id5aba6cd215d4e19f8b583a81e5599daa9bbe12d
Signed-off-by: Magic_J <panda.magic.j@gmail.com>
Signed-off-by: Robert Varga <robert.varga@pantheon.tech>
restconf/sal-rest-docgen/src/main/java/org/opendaylight/netconf/sal/rest/doc/impl/ModelGenerator.java