diff options
Diffstat (limited to 'crypto/src/asn1/x509/AttributeCertificateInfo.cs')
-rw-r--r-- | crypto/src/asn1/x509/AttributeCertificateInfo.cs | 19 |
1 files changed, 4 insertions, 15 deletions
diff --git a/crypto/src/asn1/x509/AttributeCertificateInfo.cs b/crypto/src/asn1/x509/AttributeCertificateInfo.cs index 526f8e69b..a62b01981 100644 --- a/crypto/src/asn1/x509/AttributeCertificateInfo.cs +++ b/crypto/src/asn1/x509/AttributeCertificateInfo.cs @@ -136,21 +136,10 @@ namespace Org.BouncyCastle.Asn1.X509 */ public override Asn1Object ToAsn1Object() { - Asn1EncodableVector v = new Asn1EncodableVector( - version, holder, issuer, signature, serialNumber, - attrCertValidityPeriod, attributes); - - if (issuerUniqueID != null) - { - v.Add(issuerUniqueID); - } - - if (extensions != null) - { - v.Add(extensions); - } - - return new DerSequence(v); + Asn1EncodableVector v = new Asn1EncodableVector(version, holder, issuer, signature, serialNumber, + attrCertValidityPeriod, attributes); + v.AddOptional(issuerUniqueID, extensions); + return new DerSequence(v); } } } |