Skip to content

HTTPS clone URL

Subversion checkout URL

You can clone with HTTPS or Subversion.

Download ZIP

Loading…

Fixing ProviderName check that fails because it returns an empty string #192

Merged
merged 1 commit into from

2 participants

tsquires Rob Conery
tsquires

Hey Rob,

I didn't have a providerName specified in my connection string and it found an empty string and didn't use the default providerName.

Thanks,
Tim

Rob Conery robconery merged commit dd96720 into from
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
This page is out of date. Refresh to see the latest.
Showing with 1 addition and 1 deletion.
  1. +1 −1  Massive.cs
2  Massive.cs
View
@@ -120,7 +120,7 @@ public class DynamicModel : DynamicObject {
DescriptorField = descriptorField;
var _providerName = "System.Data.SqlClient";
- if(ConfigurationManager.ConnectionStrings[connectionStringName].ProviderName != null)
+ if (!string.IsNullOrWhiteSpace(ConfigurationManager.ConnectionStrings[connectionStringName].ProviderName))
_providerName = ConfigurationManager.ConnectionStrings[connectionStringName].ProviderName;
_factory = DbProviderFactories.GetFactory(_providerName);
Something went wrong with that request. Please try again.