Skip to content

Prevent multiexecute on parameters with type IDynamicMetaObjectProvider or IEnumerable<KeyValuePair<string, object>> #151

@dennis-apter

Description

@dennis-apter

I use ExpandoObject for initialize Execute() method parameters. If take a look at SqlMapper.Execute() method, multiExec enabled for IEnumeable param, but it's unexpected behavior with ExpandoObject. Please, refine conditions like this:

if (multiExec != null && !(multiExec is string) &&
    // additional conditions:
    !(multiExec is IDynamicMetaObjectProvider) &&
    !(multiExec is IEnumerable<KeyValuePair<string, object>>))
{
    // execute as multiExec
}

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type
    No fields configured for issues without a type.

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions