summaryrefslogtreecommitdiffstats
path: root/src/DotNetOAuth/ChannelElements/OAuthChannel.cs
diff options
context:
space:
mode:
authorAndrew Arnott <andrewarnott@gmail.com>2008-11-01 20:57:22 -0700
committerAndrew <andrewarnott@gmail.com>2008-11-01 20:57:22 -0700
commite3b0e50c390de98c9aadcf10451fd17611ad431b (patch)
treef182aa5ee46b1dc3086b4ca0693b41ab84d03032 /src/DotNetOAuth/ChannelElements/OAuthChannel.cs
parentdb11b0a9fa4a304400ca1223427c3ca37f10004e (diff)
downloadDotNetOpenAuth-e3b0e50c390de98c9aadcf10451fd17611ad431b.zip
DotNetOpenAuth-e3b0e50c390de98c9aadcf10451fd17611ad431b.tar.gz
DotNetOpenAuth-e3b0e50c390de98c9aadcf10451fd17611ad431b.tar.bz2
Hugely refactored ServiceProvider and Consumer classes.
Messages are now exposed in the method signatures instead of raw Response instances.
Diffstat (limited to 'src/DotNetOAuth/ChannelElements/OAuthChannel.cs')
-rw-r--r--src/DotNetOAuth/ChannelElements/OAuthChannel.cs2
1 files changed, 2 insertions, 0 deletions
diff --git a/src/DotNetOAuth/ChannelElements/OAuthChannel.cs b/src/DotNetOAuth/ChannelElements/OAuthChannel.cs
index 16e7006..7ac4527 100644
--- a/src/DotNetOAuth/ChannelElements/OAuthChannel.cs
+++ b/src/DotNetOAuth/ChannelElements/OAuthChannel.cs
@@ -236,6 +236,8 @@ namespace DotNetOAuth.ChannelElements {
/// This method implements spec V1.0 section 5.3.
/// </remarks>
protected override Response SendDirectMessageResponse(IProtocolMessage response) {
+ if (response == null) throw new ArgumentNullException("response");
+
MessageSerializer serializer = MessageSerializer.Get(response.GetType());
var fields = serializer.Serialize(response);
string responseBody = MessagingUtilities.CreateQueryString(fields);