AuthorizeNet/sdk-dotnet

View on GitHub

Showing 471 of 545 total issues

Similar blocks of code found in 37 locations. Consider refactoring.
Open

            foreach (var anEnum in Enum.GetValues(typeof(CustomerPaymentProfileOrderFieldEnum)))
            {
                var aValue = anEnum.ToString();
                CustomerPaymentProfileOrderFieldEnum enumFromValue;
                Assert.IsTrue(Enum.TryParse(aValue, out enumFromValue));
Severity: Major
Found in AuthorizeNETtest/Api/Controllers/Test/AllGeneratedEnumTest.cs and 36 other locations - About 50 mins to fix
AuthorizeNETtest/Api/Controllers/Test/AllGeneratedEnumTest.cs on lines 40..46
AuthorizeNETtest/Api/Controllers/Test/AllGeneratedEnumTest.cs on lines 48..54
AuthorizeNETtest/Api/Controllers/Test/AllGeneratedEnumTest.cs on lines 56..62
AuthorizeNETtest/Api/Controllers/Test/AllGeneratedEnumTest.cs on lines 64..70
AuthorizeNETtest/Api/Controllers/Test/AllGeneratedEnumTest.cs on lines 72..78
AuthorizeNETtest/Api/Controllers/Test/AllGeneratedEnumTest.cs on lines 80..86
AuthorizeNETtest/Api/Controllers/Test/AllGeneratedEnumTest.cs on lines 88..94
AuthorizeNETtest/Api/Controllers/Test/AllGeneratedEnumTest.cs on lines 96..102
AuthorizeNETtest/Api/Controllers/Test/AllGeneratedEnumTest.cs on lines 104..110
AuthorizeNETtest/Api/Controllers/Test/AllGeneratedEnumTest.cs on lines 112..118
AuthorizeNETtest/Api/Controllers/Test/AllGeneratedEnumTest.cs on lines 120..126
AuthorizeNETtest/Api/Controllers/Test/AllGeneratedEnumTest.cs on lines 128..134
AuthorizeNETtest/Api/Controllers/Test/AllGeneratedEnumTest.cs on lines 136..142
AuthorizeNETtest/Api/Controllers/Test/AllGeneratedEnumTest.cs on lines 144..150
AuthorizeNETtest/Api/Controllers/Test/AllGeneratedEnumTest.cs on lines 152..158
AuthorizeNETtest/Api/Controllers/Test/AllGeneratedEnumTest.cs on lines 160..166
AuthorizeNETtest/Api/Controllers/Test/AllGeneratedEnumTest.cs on lines 168..174
AuthorizeNETtest/Api/Controllers/Test/AllGeneratedEnumTest.cs on lines 176..182
AuthorizeNETtest/Api/Controllers/Test/AllGeneratedEnumTest.cs on lines 184..190
AuthorizeNETtest/Api/Controllers/Test/AllGeneratedEnumTest.cs on lines 192..198
AuthorizeNETtest/Api/Controllers/Test/AllGeneratedEnumTest.cs on lines 199..205
AuthorizeNETtest/Api/Controllers/Test/AllGeneratedEnumTest.cs on lines 207..213
AuthorizeNETtest/Api/Controllers/Test/AllGeneratedEnumTest.cs on lines 215..221
AuthorizeNETtest/Api/Controllers/Test/AllGeneratedEnumTest.cs on lines 223..229
AuthorizeNETtest/Api/Controllers/Test/AllGeneratedEnumTest.cs on lines 231..237
AuthorizeNETtest/Api/Controllers/Test/AllGeneratedEnumTest.cs on lines 239..245
AuthorizeNETtest/Api/Controllers/Test/AllGeneratedEnumTest.cs on lines 247..253
AuthorizeNETtest/Api/Controllers/Test/AllGeneratedEnumTest.cs on lines 255..261
AuthorizeNETtest/Api/Controllers/Test/AllGeneratedEnumTest.cs on lines 263..269
AuthorizeNETtest/Api/Controllers/Test/AllGeneratedEnumTest.cs on lines 271..277
AuthorizeNETtest/Api/Controllers/Test/AllGeneratedEnumTest.cs on lines 279..285
AuthorizeNETtest/Api/Controllers/Test/AllGeneratedEnumTest.cs on lines 287..293
AuthorizeNETtest/Api/Controllers/Test/AllGeneratedEnumTest.cs on lines 295..301
AuthorizeNETtest/Api/Controllers/Test/AllGeneratedEnumTest.cs on lines 303..309
AuthorizeNETtest/Api/Controllers/Test/AllGeneratedEnumTest.cs on lines 319..325
AuthorizeNETtest/Api/Controllers/Test/AllGeneratedEnumTest.cs on lines 327..333

Duplicated Code

Duplicated code can lead to software that is hard to understand and difficult to change. The Don't Repeat Yourself (DRY) principle states:

Every piece of knowledge must have a single, unambiguous, authoritative representation within a system.

When you violate DRY, bugs and maintenance problems are sure to follow. Duplicated code has a tendency to both continue to replicate and also to diverge (leaving bugs as two similar implementations differ in subtle ways).

Tuning

This issue has a mass of 82.

We set useful threshold defaults for the languages we support but you may want to adjust these settings based on your project guidelines.

The threshold configuration represents the minimum mass a code block must have to be analyzed for duplication. The lower the threshold, the more fine-grained the comparison.

If the engine is too easily reporting duplication, try raising the threshold. If you suspect that the engine isn't catching enough duplication, try lowering the threshold. The best setting tends to differ from language to language.

See codeclimate-duplication's documentation for more information about tuning the mass threshold in your .codeclimate.yml.

Refactorings

Further Reading

Similar blocks of code found in 2 locations. Consider refactoring.
Open

    [System.CodeDom.Compiler.GeneratedCodeAttribute("xsd", "4.6.1055.0")]
    [System.SerializableAttribute()]
    [System.Xml.Serialization.XmlTypeAttribute(Namespace="AnetApi/xml/v1/schema/AnetApiSchema.xsd")]
    public enum transactionStatusEnum {
        
Severity: Minor
Found in Authorize.NET/Api/Contracts/V1/AnetApiSchema.generated.cs and 1 other location - About 50 mins to fix
Authorize.NET/Utility/AnetApiSchema.generated.cs on lines 5235..5311

Duplicated Code

Duplicated code can lead to software that is hard to understand and difficult to change. The Don't Repeat Yourself (DRY) principle states:

Every piece of knowledge must have a single, unambiguous, authoritative representation within a system.

When you violate DRY, bugs and maintenance problems are sure to follow. Duplicated code has a tendency to both continue to replicate and also to diverge (leaving bugs as two similar implementations differ in subtle ways).

Tuning

This issue has a mass of 79.

We set useful threshold defaults for the languages we support but you may want to adjust these settings based on your project guidelines.

The threshold configuration represents the minimum mass a code block must have to be analyzed for duplication. The lower the threshold, the more fine-grained the comparison.

If the engine is too easily reporting duplication, try raising the threshold. If you suspect that the engine isn't catching enough duplication, try lowering the threshold. The best setting tends to differ from language to language.

See codeclimate-duplication's documentation for more information about tuning the mass threshold in your .codeclimate.yml.

Refactorings

Further Reading

Similar blocks of code found in 2 locations. Consider refactoring.
Open

        protected static TS ExecuteTestRequestWithFailure<TQ, TS, TT>(TQ request, AuthorizeNet.Environment execEnvironment = null)
            where TQ : ANetApiRequest
            where TS : ANetApiResponse
            where TT : ApiOperationBase<TQ, TS> 
        {
Severity: Minor
Found in AuthorizeNETtest/Api/Controllers/Test/ApiCoreTestBase.cs and 1 other location - About 50 mins to fix
AuthorizeNETtest/Api/Controllers/Test/ApiCoreTestBase.cs on lines 377..385

Duplicated Code

Duplicated code can lead to software that is hard to understand and difficult to change. The Don't Repeat Yourself (DRY) principle states:

Every piece of knowledge must have a single, unambiguous, authoritative representation within a system.

When you violate DRY, bugs and maintenance problems are sure to follow. Duplicated code has a tendency to both continue to replicate and also to diverge (leaving bugs as two similar implementations differ in subtle ways).

Tuning

This issue has a mass of 79.

We set useful threshold defaults for the languages we support but you may want to adjust these settings based on your project guidelines.

The threshold configuration represents the minimum mass a code block must have to be analyzed for duplication. The lower the threshold, the more fine-grained the comparison.

If the engine is too easily reporting duplication, try raising the threshold. If you suspect that the engine isn't catching enough duplication, try lowering the threshold. The best setting tends to differ from language to language.

See codeclimate-duplication's documentation for more information about tuning the mass threshold in your .codeclimate.yml.

Refactorings

Further Reading

Similar blocks of code found in 2 locations. Consider refactoring.
Open

        protected static TS ExecuteTestRequestWithSuccess<TQ, TS, TT>(TQ request, AuthorizeNet.Environment execEnvironment = null)
            where TQ : ANetApiRequest
            where TS : ANetApiResponse
            where TT : ApiOperationBase<TQ, TS> 
        {
Severity: Minor
Found in AuthorizeNETtest/Api/Controllers/Test/ApiCoreTestBase.cs and 1 other location - About 50 mins to fix
AuthorizeNETtest/Api/Controllers/Test/ApiCoreTestBase.cs on lines 387..395

Duplicated Code

Duplicated code can lead to software that is hard to understand and difficult to change. The Don't Repeat Yourself (DRY) principle states:

Every piece of knowledge must have a single, unambiguous, authoritative representation within a system.

When you violate DRY, bugs and maintenance problems are sure to follow. Duplicated code has a tendency to both continue to replicate and also to diverge (leaving bugs as two similar implementations differ in subtle ways).

Tuning

This issue has a mass of 79.

We set useful threshold defaults for the languages we support but you may want to adjust these settings based on your project guidelines.

The threshold configuration represents the minimum mass a code block must have to be analyzed for duplication. The lower the threshold, the more fine-grained the comparison.

If the engine is too easily reporting duplication, try raising the threshold. If you suspect that the engine isn't catching enough duplication, try lowering the threshold. The best setting tends to differ from language to language.

See codeclimate-duplication's documentation for more information about tuning the mass threshold in your .codeclimate.yml.

Refactorings

Further Reading

Similar blocks of code found in 2 locations. Consider refactoring.
Open

    [System.CodeDom.Compiler.GeneratedCodeAttribute("xsd", "2.0.50727.3038")]
    [System.SerializableAttribute()]
    [System.Xml.Serialization.XmlTypeAttribute(Namespace="AnetApi/xml/v1/schema/AnetApiSchema.xsd")]
    public enum transactionStatusEnum {
        
Severity: Minor
Found in Authorize.NET/Utility/AnetApiSchema.generated.cs and 1 other location - About 50 mins to fix
Authorize.NET/Api/Contracts/V1/AnetApiSchema.generated.cs on lines 6135..6211

Duplicated Code

Duplicated code can lead to software that is hard to understand and difficult to change. The Don't Repeat Yourself (DRY) principle states:

Every piece of knowledge must have a single, unambiguous, authoritative representation within a system.

When you violate DRY, bugs and maintenance problems are sure to follow. Duplicated code has a tendency to both continue to replicate and also to diverge (leaving bugs as two similar implementations differ in subtle ways).

Tuning

This issue has a mass of 79.

We set useful threshold defaults for the languages we support but you may want to adjust these settings based on your project guidelines.

The threshold configuration represents the minimum mass a code block must have to be analyzed for duplication. The lower the threshold, the more fine-grained the comparison.

If the engine is too easily reporting duplication, try raising the threshold. If you suspect that the engine isn't catching enough duplication, try lowering the threshold. The best setting tends to differ from language to language.

See codeclimate-duplication's documentation for more information about tuning the mass threshold in your .codeclimate.yml.

Refactorings

Further Reading

Identical blocks of code found in 2 locations. Consider refactoring.
Open

        [System.Xml.Serialization.XmlElementAttribute("bankAccount", typeof(bankAccountMaskedType))]
        [System.Xml.Serialization.XmlElementAttribute("creditCard", typeof(creditCardMaskedType))]
        [System.Xml.Serialization.XmlElementAttribute("tokenInformation", typeof(tokenMaskedType))]
        public object Item;
Severity: Minor
Found in Authorize.NET/Api/Contracts/V1/AnetApiSchema.generated.cs and 1 other location - About 50 mins to fix
Authorize.NET/Utility/AnetApiSchema.generated.cs on lines 323..326

Duplicated Code

Duplicated code can lead to software that is hard to understand and difficult to change. The Don't Repeat Yourself (DRY) principle states:

Every piece of knowledge must have a single, unambiguous, authoritative representation within a system.

When you violate DRY, bugs and maintenance problems are sure to follow. Duplicated code has a tendency to both continue to replicate and also to diverge (leaving bugs as two similar implementations differ in subtle ways).

Tuning

This issue has a mass of 78.

We set useful threshold defaults for the languages we support but you may want to adjust these settings based on your project guidelines.

The threshold configuration represents the minimum mass a code block must have to be analyzed for duplication. The lower the threshold, the more fine-grained the comparison.

If the engine is too easily reporting duplication, try raising the threshold. If you suspect that the engine isn't catching enough duplication, try lowering the threshold. The best setting tends to differ from language to language.

See codeclimate-duplication's documentation for more information about tuning the mass threshold in your .codeclimate.yml.

Refactorings

Further Reading

Identical blocks of code found in 2 locations. Consider refactoring.
Open

        [System.Xml.Serialization.XmlElementAttribute("bankAccount", typeof(bankAccountMaskedType))]
        [System.Xml.Serialization.XmlElementAttribute("creditCard", typeof(creditCardMaskedType))]
        [System.Xml.Serialization.XmlElementAttribute("tokenInformation", typeof(tokenMaskedType))]
        public object Item;
Severity: Minor
Found in Authorize.NET/Utility/AnetApiSchema.generated.cs and 1 other location - About 50 mins to fix
Authorize.NET/Api/Contracts/V1/AnetApiSchema.generated.cs on lines 395..398

Duplicated Code

Duplicated code can lead to software that is hard to understand and difficult to change. The Don't Repeat Yourself (DRY) principle states:

Every piece of knowledge must have a single, unambiguous, authoritative representation within a system.

When you violate DRY, bugs and maintenance problems are sure to follow. Duplicated code has a tendency to both continue to replicate and also to diverge (leaving bugs as two similar implementations differ in subtle ways).

Tuning

This issue has a mass of 78.

We set useful threshold defaults for the languages we support but you may want to adjust these settings based on your project guidelines.

The threshold configuration represents the minimum mass a code block must have to be analyzed for duplication. The lower the threshold, the more fine-grained the comparison.

If the engine is too easily reporting duplication, try raising the threshold. If you suspect that the engine isn't catching enough duplication, try lowering the threshold. The best setting tends to differ from language to language.

See codeclimate-duplication's documentation for more information about tuning the mass threshold in your .codeclimate.yml.

Refactorings

Further Reading

Similar blocks of code found in 3 locations. Consider refactoring.
Open

namespace AuthorizeNet.Api.Controllers
{
    using System;
    using AuthorizeNet.Api.Contracts.V1;
    using AuthorizeNet.Api.Controllers.Bases;
Severity: Major
Found in Authorize.NET/Api/Controllers/getAUJobDetailsController.cs and 2 other locations - About 45 mins to fix
Authorize.NET/Api/Controllers/getAUJobSummaryController.cs on lines 1..29
Authorize.NET/Api/Controllers/getCustomerPaymentProfileNonceController.cs on lines 1..30

Duplicated Code

Duplicated code can lead to software that is hard to understand and difficult to change. The Don't Repeat Yourself (DRY) principle states:

Every piece of knowledge must have a single, unambiguous, authoritative representation within a system.

When you violate DRY, bugs and maintenance problems are sure to follow. Duplicated code has a tendency to both continue to replicate and also to diverge (leaving bugs as two similar implementations differ in subtle ways).

Tuning

This issue has a mass of 75.

We set useful threshold defaults for the languages we support but you may want to adjust these settings based on your project guidelines.

The threshold configuration represents the minimum mass a code block must have to be analyzed for duplication. The lower the threshold, the more fine-grained the comparison.

If the engine is too easily reporting duplication, try raising the threshold. If you suspect that the engine isn't catching enough duplication, try lowering the threshold. The best setting tends to differ from language to language.

See codeclimate-duplication's documentation for more information about tuning the mass threshold in your .codeclimate.yml.

Refactorings

Further Reading

Similar blocks of code found in 3 locations. Consider refactoring.
Open

namespace AuthorizeNet.Api.Controllers
{
    using System;
    using AuthorizeNet.Api.Contracts.V1;
    using AuthorizeNet.Api.Controllers.Bases;
Authorize.NET/Api/Controllers/getAUJobDetailsController.cs on lines 1..29
Authorize.NET/Api/Controllers/getAUJobSummaryController.cs on lines 1..29

Duplicated Code

Duplicated code can lead to software that is hard to understand and difficult to change. The Don't Repeat Yourself (DRY) principle states:

Every piece of knowledge must have a single, unambiguous, authoritative representation within a system.

When you violate DRY, bugs and maintenance problems are sure to follow. Duplicated code has a tendency to both continue to replicate and also to diverge (leaving bugs as two similar implementations differ in subtle ways).

Tuning

This issue has a mass of 75.

We set useful threshold defaults for the languages we support but you may want to adjust these settings based on your project guidelines.

The threshold configuration represents the minimum mass a code block must have to be analyzed for duplication. The lower the threshold, the more fine-grained the comparison.

If the engine is too easily reporting duplication, try raising the threshold. If you suspect that the engine isn't catching enough duplication, try lowering the threshold. The best setting tends to differ from language to language.

See codeclimate-duplication's documentation for more information about tuning the mass threshold in your .codeclimate.yml.

Refactorings

Further Reading

Similar blocks of code found in 3 locations. Consider refactoring.
Open

namespace AuthorizeNet.Api.Controllers
{
    using System;
    using AuthorizeNet.Api.Contracts.V1;
    using AuthorizeNet.Api.Controllers.Bases;
Severity: Major
Found in Authorize.NET/Api/Controllers/getAUJobSummaryController.cs and 2 other locations - About 45 mins to fix
Authorize.NET/Api/Controllers/getAUJobDetailsController.cs on lines 1..29
Authorize.NET/Api/Controllers/getCustomerPaymentProfileNonceController.cs on lines 1..30

Duplicated Code

Duplicated code can lead to software that is hard to understand and difficult to change. The Don't Repeat Yourself (DRY) principle states:

Every piece of knowledge must have a single, unambiguous, authoritative representation within a system.

When you violate DRY, bugs and maintenance problems are sure to follow. Duplicated code has a tendency to both continue to replicate and also to diverge (leaving bugs as two similar implementations differ in subtle ways).

Tuning

This issue has a mass of 75.

We set useful threshold defaults for the languages we support but you may want to adjust these settings based on your project guidelines.

The threshold configuration represents the minimum mass a code block must have to be analyzed for duplication. The lower the threshold, the more fine-grained the comparison.

If the engine is too easily reporting duplication, try raising the threshold. If you suspect that the engine isn't catching enough duplication, try lowering the threshold. The best setting tends to differ from language to language.

See codeclimate-duplication's documentation for more information about tuning the mass threshold in your .codeclimate.yml.

Refactorings

Further Reading

Similar blocks of code found in 2 locations. Consider refactoring.
Open

namespace AuthorizeNet.Api.Controllers
{
    using System;
    using AuthorizeNet.Api.Contracts.V1;
    using AuthorizeNet.Api.Controllers.Bases;
Authorize.NET/Api/Controllers/createCustomerProfileTransactionController.cs on lines 1..23

Duplicated Code

Duplicated code can lead to software that is hard to understand and difficult to change. The Don't Repeat Yourself (DRY) principle states:

Every piece of knowledge must have a single, unambiguous, authoritative representation within a system.

When you violate DRY, bugs and maintenance problems are sure to follow. Duplicated code has a tendency to both continue to replicate and also to diverge (leaving bugs as two similar implementations differ in subtle ways).

Tuning

This issue has a mass of 75.

We set useful threshold defaults for the languages we support but you may want to adjust these settings based on your project guidelines.

The threshold configuration represents the minimum mass a code block must have to be analyzed for duplication. The lower the threshold, the more fine-grained the comparison.

If the engine is too easily reporting duplication, try raising the threshold. If you suspect that the engine isn't catching enough duplication, try lowering the threshold. The best setting tends to differ from language to language.

See codeclimate-duplication's documentation for more information about tuning the mass threshold in your .codeclimate.yml.

Refactorings

Further Reading

Similar blocks of code found in 2 locations. Consider refactoring.
Open

namespace AuthorizeNet.Api.Controllers
{
    using System;
    using AuthorizeNet.Api.Contracts.V1;
    using AuthorizeNet.Api.Controllers.Bases;
Authorize.NET/Api/Controllers/createCustomerProfileFromTransactionController.cs on lines 1..26

Duplicated Code

Duplicated code can lead to software that is hard to understand and difficult to change. The Don't Repeat Yourself (DRY) principle states:

Every piece of knowledge must have a single, unambiguous, authoritative representation within a system.

When you violate DRY, bugs and maintenance problems are sure to follow. Duplicated code has a tendency to both continue to replicate and also to diverge (leaving bugs as two similar implementations differ in subtle ways).

Tuning

This issue has a mass of 75.

We set useful threshold defaults for the languages we support but you may want to adjust these settings based on your project guidelines.

The threshold configuration represents the minimum mass a code block must have to be analyzed for duplication. The lower the threshold, the more fine-grained the comparison.

If the engine is too easily reporting duplication, try raising the threshold. If you suspect that the engine isn't catching enough duplication, try lowering the threshold. The best setting tends to differ from language to language.

See codeclimate-duplication's documentation for more information about tuning the mass threshold in your .codeclimate.yml.

Refactorings

Further Reading

Identical blocks of code found in 2 locations. Consider refactoring.
Open

        [System.Xml.Serialization.XmlElementAttribute("track1", typeof(string))]
        [System.Xml.Serialization.XmlElementAttribute("track2", typeof(string))]
        [System.Xml.Serialization.XmlChoiceIdentifierAttribute("ItemElementName")]
        public string Item;
Severity: Minor
Found in Authorize.NET/Utility/AnetApiSchema.generated.cs and 1 other location - About 45 mins to fix
Authorize.NET/Api/Contracts/V1/AnetApiSchema.generated.cs on lines 3215..3218

Duplicated Code

Duplicated code can lead to software that is hard to understand and difficult to change. The Don't Repeat Yourself (DRY) principle states:

Every piece of knowledge must have a single, unambiguous, authoritative representation within a system.

When you violate DRY, bugs and maintenance problems are sure to follow. Duplicated code has a tendency to both continue to replicate and also to diverge (leaving bugs as two similar implementations differ in subtle ways).

Tuning

This issue has a mass of 73.

We set useful threshold defaults for the languages we support but you may want to adjust these settings based on your project guidelines.

The threshold configuration represents the minimum mass a code block must have to be analyzed for duplication. The lower the threshold, the more fine-grained the comparison.

If the engine is too easily reporting duplication, try raising the threshold. If you suspect that the engine isn't catching enough duplication, try lowering the threshold. The best setting tends to differ from language to language.

See codeclimate-duplication's documentation for more information about tuning the mass threshold in your .codeclimate.yml.

Refactorings

Further Reading

Identical blocks of code found in 2 locations. Consider refactoring.
Open

        [System.Xml.Serialization.XmlElementAttribute("track1", typeof(string))]
        [System.Xml.Serialization.XmlElementAttribute("track2", typeof(string))]
        [System.Xml.Serialization.XmlChoiceIdentifierAttribute("ItemElementName")]
        public string Item;
Severity: Minor
Found in Authorize.NET/Api/Contracts/V1/AnetApiSchema.generated.cs and 1 other location - About 45 mins to fix
Authorize.NET/Utility/AnetApiSchema.generated.cs on lines 2612..2615

Duplicated Code

Duplicated code can lead to software that is hard to understand and difficult to change. The Don't Repeat Yourself (DRY) principle states:

Every piece of knowledge must have a single, unambiguous, authoritative representation within a system.

When you violate DRY, bugs and maintenance problems are sure to follow. Duplicated code has a tendency to both continue to replicate and also to diverge (leaving bugs as two similar implementations differ in subtle ways).

Tuning

This issue has a mass of 73.

We set useful threshold defaults for the languages we support but you may want to adjust these settings based on your project guidelines.

The threshold configuration represents the minimum mass a code block must have to be analyzed for duplication. The lower the threshold, the more fine-grained the comparison.

If the engine is too easily reporting duplication, try raising the threshold. If you suspect that the engine isn't catching enough duplication, try lowering the threshold. The best setting tends to differ from language to language.

See codeclimate-duplication's documentation for more information about tuning the mass threshold in your .codeclimate.yml.

Refactorings

Further Reading

Similar blocks of code found in 2 locations. Consider refactoring.
Open

        public static void paymentSimpleType(paymentSimpleType argument)
        {
            if (null != argument)
            {
                if (argument.Item is bankAccountType) { bankAccountType(argument.Item as bankAccountType); }
Severity: Minor
Found in Authorize.NET/Api/Contracts/V1/RequestFactoryWithSpecified.cs and 1 other location - About 40 mins to fix
Authorize.NET/Api/Contracts/V1/RequestFactoryWithSpecified.cs on lines 938..948

Duplicated Code

Duplicated code can lead to software that is hard to understand and difficult to change. The Don't Repeat Yourself (DRY) principle states:

Every piece of knowledge must have a single, unambiguous, authoritative representation within a system.

When you violate DRY, bugs and maintenance problems are sure to follow. Duplicated code has a tendency to both continue to replicate and also to diverge (leaving bugs as two similar implementations differ in subtle ways).

Tuning

This issue has a mass of 72.

We set useful threshold defaults for the languages we support but you may want to adjust these settings based on your project guidelines.

The threshold configuration represents the minimum mass a code block must have to be analyzed for duplication. The lower the threshold, the more fine-grained the comparison.

If the engine is too easily reporting duplication, try raising the threshold. If you suspect that the engine isn't catching enough duplication, try lowering the threshold. The best setting tends to differ from language to language.

See codeclimate-duplication's documentation for more information about tuning the mass threshold in your .codeclimate.yml.

Refactorings

Further Reading

Similar blocks of code found in 2 locations. Consider refactoring.
Open

        public static void merchantAuthenticationType(merchantAuthenticationType argument)
        {
            if (null != argument)
            {
                if (argument.Item is fingerPrintType)
Severity: Minor
Found in Authorize.NET/Api/Contracts/V1/RequestFactoryWithSpecified.cs and 1 other location - About 40 mins to fix
Authorize.NET/Api/Contracts/V1/RequestFactoryWithSpecified.cs on lines 83..90

Duplicated Code

Duplicated code can lead to software that is hard to understand and difficult to change. The Don't Repeat Yourself (DRY) principle states:

Every piece of knowledge must have a single, unambiguous, authoritative representation within a system.

When you violate DRY, bugs and maintenance problems are sure to follow. Duplicated code has a tendency to both continue to replicate and also to diverge (leaving bugs as two similar implementations differ in subtle ways).

Tuning

This issue has a mass of 72.

We set useful threshold defaults for the languages we support but you may want to adjust these settings based on your project guidelines.

The threshold configuration represents the minimum mass a code block must have to be analyzed for duplication. The lower the threshold, the more fine-grained the comparison.

If the engine is too easily reporting duplication, try raising the threshold. If you suspect that the engine isn't catching enough duplication, try lowering the threshold. The best setting tends to differ from language to language.

See codeclimate-duplication's documentation for more information about tuning the mass threshold in your .codeclimate.yml.

Refactorings

Further Reading

Similar blocks of code found in 2 locations. Consider refactoring.
Open

    [System.CodeDom.Compiler.GeneratedCodeAttribute("xsd", "4.6.1055.0")]
    [System.SerializableAttribute()]
    [System.Xml.Serialization.XmlTypeAttribute(Namespace="AnetApi/xml/v1/schema/AnetApiSchema.xsd")]
    public enum paymentMethodsTypeEnum {
        
Severity: Minor
Found in Authorize.NET/Api/Contracts/V1/AnetApiSchema.generated.cs and 1 other location - About 40 mins to fix
Authorize.NET/Utility/AnetApiSchema.generated.cs on lines 5606..5649

Duplicated Code

Duplicated code can lead to software that is hard to understand and difficult to change. The Don't Repeat Yourself (DRY) principle states:

Every piece of knowledge must have a single, unambiguous, authoritative representation within a system.

When you violate DRY, bugs and maintenance problems are sure to follow. Duplicated code has a tendency to both continue to replicate and also to diverge (leaving bugs as two similar implementations differ in subtle ways).

Tuning

This issue has a mass of 68.

We set useful threshold defaults for the languages we support but you may want to adjust these settings based on your project guidelines.

The threshold configuration represents the minimum mass a code block must have to be analyzed for duplication. The lower the threshold, the more fine-grained the comparison.

If the engine is too easily reporting duplication, try raising the threshold. If you suspect that the engine isn't catching enough duplication, try lowering the threshold. The best setting tends to differ from language to language.

See codeclimate-duplication's documentation for more information about tuning the mass threshold in your .codeclimate.yml.

Refactorings

Further Reading

Similar blocks of code found in 3 locations. Consider refactoring.
Open

        public static bool ParseBool(string boolstringValue) {
            bool result = false;
        
            if ( null != boolstringValue && 0 < boolstringValue.Trim().Length)
            {
Severity: Minor
Found in Authorize.NET/Util/StringUtils.cs and 2 other locations - About 40 mins to fix
Authorize.NET/Util/StringUtils.cs on lines 17..26
Authorize.NET/Util/StringUtils.cs on lines 33..42

Duplicated Code

Duplicated code can lead to software that is hard to understand and difficult to change. The Don't Repeat Yourself (DRY) principle states:

Every piece of knowledge must have a single, unambiguous, authoritative representation within a system.

When you violate DRY, bugs and maintenance problems are sure to follow. Duplicated code has a tendency to both continue to replicate and also to diverge (leaving bugs as two similar implementations differ in subtle ways).

Tuning

This issue has a mass of 68.

We set useful threshold defaults for the languages we support but you may want to adjust these settings based on your project guidelines.

The threshold configuration represents the minimum mass a code block must have to be analyzed for duplication. The lower the threshold, the more fine-grained the comparison.

If the engine is too easily reporting duplication, try raising the threshold. If you suspect that the engine isn't catching enough duplication, try lowering the threshold. The best setting tends to differ from language to language.

See codeclimate-duplication's documentation for more information about tuning the mass threshold in your .codeclimate.yml.

Refactorings

Further Reading

Similar blocks of code found in 2 locations. Consider refactoring.
Open

        public static void ARBGetSubscriptionListResponse(ARBGetSubscriptionListResponse argument)
        {
            if (null != argument)
            {
                if (0 <= argument.totalNumInResultSet) { argument.totalNumInResultSetSpecified = true; }
Severity: Minor
Found in Authorize.NET/Api/Contracts/V1/RequestFactoryWithSpecified.cs and 1 other location - About 40 mins to fix
Authorize.NET/Api/Contracts/V1/RequestFactoryWithSpecified.cs on lines 1621..1628

Duplicated Code

Duplicated code can lead to software that is hard to understand and difficult to change. The Don't Repeat Yourself (DRY) principle states:

Every piece of knowledge must have a single, unambiguous, authoritative representation within a system.

When you violate DRY, bugs and maintenance problems are sure to follow. Duplicated code has a tendency to both continue to replicate and also to diverge (leaving bugs as two similar implementations differ in subtle ways).

Tuning

This issue has a mass of 68.

We set useful threshold defaults for the languages we support but you may want to adjust these settings based on your project guidelines.

The threshold configuration represents the minimum mass a code block must have to be analyzed for duplication. The lower the threshold, the more fine-grained the comparison.

If the engine is too easily reporting duplication, try raising the threshold. If you suspect that the engine isn't catching enough duplication, try lowering the threshold. The best setting tends to differ from language to language.

See codeclimate-duplication's documentation for more information about tuning the mass threshold in your .codeclimate.yml.

Refactorings

Further Reading

Similar blocks of code found in 2 locations. Consider refactoring.
Open

        public static void getUnsettledTransactionListResponse(getUnsettledTransactionListResponse argument)
        {
            if (null != argument)
            {
                if (null != argument.transactions) { foreach (var value in argument.transactions) { transactionSummaryType(value); } }
Severity: Minor
Found in Authorize.NET/Api/Contracts/V1/RequestFactoryWithSpecified.cs and 1 other location - About 40 mins to fix
Authorize.NET/Api/Contracts/V1/RequestFactoryWithSpecified.cs on lines 1399..1406

Duplicated Code

Duplicated code can lead to software that is hard to understand and difficult to change. The Don't Repeat Yourself (DRY) principle states:

Every piece of knowledge must have a single, unambiguous, authoritative representation within a system.

When you violate DRY, bugs and maintenance problems are sure to follow. Duplicated code has a tendency to both continue to replicate and also to diverge (leaving bugs as two similar implementations differ in subtle ways).

Tuning

This issue has a mass of 68.

We set useful threshold defaults for the languages we support but you may want to adjust these settings based on your project guidelines.

The threshold configuration represents the minimum mass a code block must have to be analyzed for duplication. The lower the threshold, the more fine-grained the comparison.

If the engine is too easily reporting duplication, try raising the threshold. If you suspect that the engine isn't catching enough duplication, try lowering the threshold. The best setting tends to differ from language to language.

See codeclimate-duplication's documentation for more information about tuning the mass threshold in your .codeclimate.yml.

Refactorings

Further Reading

Severity
Category
Status
Source
Language