You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@usergrid.apache.org by sn...@apache.org on 2014/04/14 00:21:02 UTC
[08/28] git commit: added review comments for the fix for bug
USERGRID-22, ICLA - Malaka Mahanama
added review comments for the fix for bug USERGRID-22, ICLA - Malaka Mahanama
Project: http://git-wip-us.apache.org/repos/asf/incubator-usergrid/repo
Commit: http://git-wip-us.apache.org/repos/asf/incubator-usergrid/commit/e186568e
Tree: http://git-wip-us.apache.org/repos/asf/incubator-usergrid/tree/e186568e
Diff: http://git-wip-us.apache.org/repos/asf/incubator-usergrid/diff/e186568e
Branch: refs/pull/106/head
Commit: e186568e0f32a78fee53b2006691337def1729e3
Parents: dbfd345
Author: Malaka <ma...@gmail.com>
Authored: Sun Apr 6 23:55:53 2014 +0530
Committer: Malaka <ma...@gmail.com>
Committed: Sun Apr 6 23:55:53 2014 +0530
----------------------------------------------------------------------
.../java/org/apache/usergrid/persistence/Query.java | 14 +++++++++-----
1 file changed, 9 insertions(+), 5 deletions(-)
----------------------------------------------------------------------
http://git-wip-us.apache.org/repos/asf/incubator-usergrid/blob/e186568e/stack/core/src/main/java/org/apache/usergrid/persistence/Query.java
----------------------------------------------------------------------
diff --git a/stack/core/src/main/java/org/apache/usergrid/persistence/Query.java b/stack/core/src/main/java/org/apache/usergrid/persistence/Query.java
index 23970f0..a2c97a6 100644
--- a/stack/core/src/main/java/org/apache/usergrid/persistence/Query.java
+++ b/stack/core/src/main/java/org/apache/usergrid/persistence/Query.java
@@ -373,8 +373,9 @@ public class Query {
for ( Identifier identifier : identifiers ) {
//part of fix for the bug USERGRID-22 (to prevent a null pointer exception).
- if (identifier == null)
- { return false; }
+ if ( identifier == null ){
+ return false;
+ }
if ( !identifier.isEmail() && !identifier.isName() ) {
return false;
@@ -420,7 +421,9 @@ public class Query {
for ( Identifier identifier : identifiers ) {
//part of fix for the bug USERGRID-22 (to prevent a null pointer exception).
- if (identifier == null){ return true; }
+ if ( identifier == null ){
+ return true;
+ }
if ( !identifier.isUUID() ) {
return false;
@@ -452,8 +455,9 @@ public class Query {
return null;
}
//part of fix for the bug USERGRID-22 (to prevent a null pointer exception).
- if(identifiers.get( 0 )==null)
- { return null; }
+ if( identifiers.get( 0 ) == null ){
+ return null;
+ }
return ( identifiers.get( 0 ).getUUID() );
}