Skip to content

Commit

Permalink
TEIID-3345: Fixing the NPE and throwing correct error message
Browse files Browse the repository at this point in the history
  • Loading branch information
rareddy committed Mar 20, 2015
1 parent f5a1d9d commit d9ca0b7
Showing 1 changed file with 4 additions and 0 deletions.
Expand Up @@ -77,6 +77,10 @@ public ODataProducer getContext(Class<?> arg0) {
vdbName = getInitParameters().getProperty("allow-vdb"); //$NON-NLS-1$
}

if (vdbName == null) {
throw new TeiidRuntimeException(ODataPlugin.Util.gs(ODataPlugin.Event.TEIID16008));
}

int versionIdx = vdbName.indexOf('.');
if (versionIdx != -1) {
version = Integer.parseInt(vdbName.substring(versionIdx+1));
Expand Down

0 comments on commit d9ca0b7

Please sign in to comment.