diff options
author | Andrew Arnott <andrewarnott@gmail.com> | 2009-03-08 20:55:25 -0700 |
---|---|---|
committer | Andrew Arnott <andrewarnott@gmail.com> | 2009-03-09 15:07:41 -0700 |
commit | 7e5285f163c073f71ea1d75b8c39f0e024366f3e (patch) | |
tree | 8019aff825671533e484685ea634f7e7645f3177 /src | |
parent | 4499e8b1db764b944764d30f838d1b7c80a7e050 (diff) | |
download | DotNetOpenAuth-7e5285f163c073f71ea1d75b8c39f0e024366f3e.zip DotNetOpenAuth-7e5285f163c073f71ea1d75b8c39f0e024366f3e.tar.gz DotNetOpenAuth-7e5285f163c073f71ea1d75b8c39f0e024366f3e.tar.bz2 |
Fixed static analysis issues.
Diffstat (limited to 'src')
-rw-r--r-- | src/DotNetOpenAuth/Messaging/MessageSerializer.cs | 15 | ||||
-rw-r--r-- | src/DotNetOpenAuth/OpenId/Interop/AuthenticationResponseShim.cs | 2 |
2 files changed, 7 insertions, 10 deletions
diff --git a/src/DotNetOpenAuth/Messaging/MessageSerializer.cs b/src/DotNetOpenAuth/Messaging/MessageSerializer.cs index 98c0bf4..523323c 100644 --- a/src/DotNetOpenAuth/Messaging/MessageSerializer.cs +++ b/src/DotNetOpenAuth/Messaging/MessageSerializer.cs @@ -32,15 +32,12 @@ namespace DotNetOpenAuth.Messaging { private MessageSerializer(Type messageType) { Debug.Assert(messageType != null, "messageType == null"); - if (!typeof(IMessage).IsAssignableFrom(messageType)) { - throw new ArgumentException( - string.Format( - CultureInfo.CurrentCulture, - MessagingStrings.UnexpectedType, - typeof(IMessage).FullName, - messageType.FullName), - "messageType"); - } + ErrorUtilities.VerifyArgumentNamed( + typeof(IMessage).IsAssignableFrom(messageType), + "messageType", + MessagingStrings.UnexpectedType, + typeof(IMessage).FullName, + messageType.FullName); this.messageType = messageType; } diff --git a/src/DotNetOpenAuth/OpenId/Interop/AuthenticationResponseShim.cs b/src/DotNetOpenAuth/OpenId/Interop/AuthenticationResponseShim.cs index 24a7100..79dbdb6 100644 --- a/src/DotNetOpenAuth/OpenId/Interop/AuthenticationResponseShim.cs +++ b/src/DotNetOpenAuth/OpenId/Interop/AuthenticationResponseShim.cs @@ -15,7 +15,7 @@ namespace DotNetOpenAuth.OpenId.Interop { /// <summary> /// The COM type used to provide details of an authentication result to a relying party COM client. /// </summary> - [SuppressMessage("Microsoft.Interoperability", "CA1409:ComVisibleTypesShouldBeCreatable")] + [SuppressMessage("Microsoft.Interoperability", "CA1409:ComVisibleTypesShouldBeCreatable", Justification = "It's only creatable on the inside. It must be ComVisible for ASP to see it.")] [ComVisible(true), Obsolete("This class acts as a COM Server and should not be called directly from .NET code.")] public class AuthenticationResponseShim { /// <summary> |