directory-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From elecha...@apache.org
Subject svn commit: r1665606 - /directory/shared/trunk/ldap/model/src/main/java/org/apache/directory/api/ldap/model/schema/registries/AbstractSchemaLoader.java
Date Tue, 10 Mar 2015 16:24:05 GMT
Author: elecharny
Date: Tue Mar 10 16:24:04 2015
New Revision: 1665606

URL: http://svn.apache.org/r1665606
Log:
Don't generate an error when we don't have the creatorsName in an entry. That would solve
DIRSTUDIO-940.

Modified:
    directory/shared/trunk/ldap/model/src/main/java/org/apache/directory/api/ldap/model/schema/registries/AbstractSchemaLoader.java

Modified: directory/shared/trunk/ldap/model/src/main/java/org/apache/directory/api/ldap/model/schema/registries/AbstractSchemaLoader.java
URL: http://svn.apache.org/viewvc/directory/shared/trunk/ldap/model/src/main/java/org/apache/directory/api/ldap/model/schema/registries/AbstractSchemaLoader.java?rev=1665606&r1=1665605&r2=1665606&view=diff
==============================================================================
--- directory/shared/trunk/ldap/model/src/main/java/org/apache/directory/api/ldap/model/schema/registries/AbstractSchemaLoader.java
(original)
+++ directory/shared/trunk/ldap/model/src/main/java/org/apache/directory/api/ldap/model/schema/registries/AbstractSchemaLoader.java
Tue Mar 10 16:24:04 2015
@@ -176,13 +176,16 @@ public abstract class AbstractSchemaLoad
 
         name = entry.get( SchemaConstants.CN_AT ).getString();
 
-        if ( entry.get( SchemaConstants.CREATORS_NAME_AT ) == null )
+        Attribute creatorsName = entry.get( SchemaConstants.CREATORS_NAME_AT );
+
+        if ( creatorsName == null )
         {
-            throw new IllegalArgumentException( "entry must have a valid " + SchemaConstants.CREATORS_NAME_AT
-                + " attribute" );
+            owner = null;
+        }
+        else
+        {
+            owner = creatorsName.getString();
         }
-
-        owner = entry.get( SchemaConstants.CREATORS_NAME_AT ).getString();
 
         if ( entry.get( MetaSchemaConstants.M_DISABLED_AT ) != null )
         {



Mime
View raw message