Permalink
Browse files

Fixed serialization bug

  • Loading branch information...
1 parent f8357d6 commit 7992f775f7205cf8e756b7683ebba3032fdc1516 @geobabbler committed Jun 20, 2012
Showing with 2 additions and 0 deletions.
  1. +1 −0 Analytics.cs
  2. +1 −0 Data/AnalyticsData.cs
View
@@ -92,6 +92,7 @@ public AnalyticsResponse Buffer(int overlayid, int distance, string units)
DataContractJsonSerializer serializer = new DataContractJsonSerializer(typeof(GeoIQ.Net.Data.AnalyticsResponse));
byte[] bytes = Encoding.ASCII.GetBytes(response);
System.IO.MemoryStream stream = new System.IO.MemoryStream(bytes);
+ stream.Position = 0;
GeoIQ.Net.Data.AnalyticsResponse result = (GeoIQ.Net.Data.AnalyticsResponse)serializer.ReadObject(stream);
//args._result = response.Status;
View
@@ -31,6 +31,7 @@ namespace GeoIQ.Net.Data
{
//{"data_type": "Dataset Analysis", "title": "Dataset from 'Maryland Towns' with a 5km buffer", "id": "251436"}
[Serializable]
+ [DataContract]
public class AnalyticsResponse
{
[DataMember(Name = "id")]

0 comments on commit 7992f77

Please sign in to comment.