From a632fbfad0ddbe8b343c6abe8e28dc41e3df9b7e Mon Sep 17 00:00:00 2001
From: Jean-Noel Rouvignac <jean-noel.rouvignac@forgerock.com>
Date: Fri, 10 Jul 2015 10:16:25 +0000
Subject: [PATCH] Code cleanup
---
opendj-server-legacy/src/main/java/org/opends/server/backends/ChangelogBackend.java | 12 ++----------
1 files changed, 2 insertions(+), 10 deletions(-)
diff --git a/opendj-server-legacy/src/main/java/org/opends/server/backends/ChangelogBackend.java b/opendj-server-legacy/src/main/java/org/opends/server/backends/ChangelogBackend.java
index e946a30..3ad9be6 100644
--- a/opendj-server-legacy/src/main/java/org/opends/server/backends/ChangelogBackend.java
+++ b/opendj-server-legacy/src/main/java/org/opends/server/backends/ChangelogBackend.java
@@ -749,11 +749,7 @@
private SearchFilter buildSearchFilterFrom(final DN baseDN, final String lowerCaseAttr, final String upperCaseAttr)
{
final RDN rdn = baseDN.rdn();
- AttributeType attrType = DirectoryServer.getAttributeType(lowerCaseAttr);
- if (attrType == null)
- {
- attrType = DirectoryServer.getDefaultAttributeType(upperCaseAttr);
- }
+ AttributeType attrType = DirectoryServer.getAttributeType(lowerCaseAttr, upperCaseAttr);
final ByteString attrValue = rdn.getAttributeValue(attrType);
if (attrValue != null)
{
@@ -1548,11 +1544,7 @@
final Map<AttributeType, List<Attribute>> userAttrs,
final Map<AttributeType, List<Attribute>> operationalAttrs, final boolean addByType)
{
- AttributeType attrType = DirectoryServer.getAttributeType(attrNameLowercase);
- if (attrType == null)
- {
- attrType = DirectoryServer.getDefaultAttributeType(attrNameUppercase);
- }
+ AttributeType attrType = DirectoryServer.getAttributeType(attrNameLowercase, attrNameUppercase);
final Attribute a = addByType
? Attributes.create(attrType, attrValue)
: Attributes.create(attrNameUppercase, attrValue);
--
Gitblit v1.10.0