#vulnerable code 
                                private static String resource( String fileName )
    {
        URL resource = StubServer.class.getClassLoader().getResource( fileName );
        if ( resource == null )
        {
            fail( fileName + " does not exists" );
        }
        return resource.getFile();
    } 
                            #location 8 
                            #vulnerability type NULL_DEREFERENCE
#fixed code
                                private static String resource( String fileName )
    {
        File resource = new File( TestNeo4j.TEST_RESOURCE_FOLDER_PATH, fileName );
        if ( !resource.exists() )
        {
            fail( fileName + " does not exists" );
        }
        return resource.getAbsolutePath();
    }