Revision: 19227
          http://sourceforge.net/p/gate/code/19227
Author:   domrout
Date:     2016-04-11 15:13:57 +0000 (Mon, 11 Apr 2016)
Log Message:
-----------
Fail sooner with NPE and a nicer message if you set entity to null.

Modified Paths:
--------------
    
gate/trunk/plugins/Crowd_Sourcing/src/gate/crowdsource/rest/CrowdFlowerClient.java

Modified: 
gate/trunk/plugins/Crowd_Sourcing/src/gate/crowdsource/rest/CrowdFlowerClient.java
===================================================================
--- 
gate/trunk/plugins/Crowd_Sourcing/src/gate/crowdsource/rest/CrowdFlowerClient.java
  2016-04-11 14:51:21 UTC (rev 19226)
+++ 
gate/trunk/plugins/Crowd_Sourcing/src/gate/crowdsource/rest/CrowdFlowerClient.java
  2016-04-11 15:13:57 UTC (rev 19227)
@@ -254,6 +254,9 @@
 
     if (target.getFeatures().containsKey("entity")) {
       entity = (String) target.getFeatures().get("entity");
+      if (entity == null) {
+        throw new NullPointerException("Given entity feature was null");
+      }
     } else {
       entity = Utils.stringFor(doc, target);
     }

This was sent by the SourceForge.net collaborative development platform, the 
world's largest Open Source development site.


------------------------------------------------------------------------------
Find and fix application performance issues faster with Applications Manager
Applications Manager provides deep performance insights into multiple tiers of
your business applications. It resolves application problems quickly and
reduces your MTTR. Get your free trial! http://pubads.g.doubleclick.net/
gampad/clk?id=1444514301&iu=/ca-pub-7940484522588532
_______________________________________________
GATE-cvs mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/gate-cvs

Reply via email to