Author: igorz Date: 2008-02-19 12:19:33 -0500 (Tue, 19 Feb 2008) New Revision: 96169
Modified: trunk/mcs/class/System.Web.Extensions/System.Web.Script.Services/ProfileService.cs Log: merge r96167:96168 Modified: trunk/mcs/class/System.Web.Extensions/System.Web.Script.Services/ProfileService.cs =================================================================== --- trunk/mcs/class/System.Web.Extensions/System.Web.Script.Services/ProfileService.cs 2008-02-19 17:17:16 UTC (rev 96168) +++ trunk/mcs/class/System.Web.Extensions/System.Web.Script.Services/ProfileService.cs 2008-02-19 17:19:33 UTC (rev 96169) @@ -84,14 +84,14 @@ } [WebMethod()] - public IDictionary<string,object> GetAllPropertiesForCurrentUser () { + public IDictionary<string, object> GetAllPropertiesForCurrentUser (bool authenticatedUserOnly) { return new ProfileSerializer (ScriptingProfileServiceSection.ReadAccessProperties); } [WebMethod ()] - public IDictionary<string, object> GetPropertiesForCurrentUser (string [] properties) { + public IDictionary<string, object> GetPropertiesForCurrentUser (string [] properties, bool authenticatedUserOnly) { if (properties == null) - return GetAllPropertiesForCurrentUser (); + return GetAllPropertiesForCurrentUser (authenticatedUserOnly); string [] raProps = ScriptingProfileServiceSection.ReadAccessPropertiesNoCopy; @@ -116,13 +116,13 @@ } [WebMethod ()] - public int SetPropertiesForCurrentUser (Dictionary<string, object> values) { + public string [] SetPropertiesForCurrentUser (Dictionary<string, object> values, bool authenticatedUserOnly) { if (values == null) - return 0; + return new string [] { }; string [] waProps = ScriptingProfileServiceSection.WriteAccessPropertiesNoCopy; - - int counter = 0; + + List<string> list = new List<string> (); ProfileBase profile = HttpContext.Current.Profile; foreach (KeyValuePair<string, object> pair in values) { try { @@ -138,13 +138,11 @@ profile.SetPropertyValue (name, pair.Value); } catch { - continue; //MS seems to ignore errors... + list.Add (pair.Key); } - - counter++; } - return counter; + return list.ToArray (); } static bool IsPropertyConfigured (string [] configuredProperties, string propertyToCheck) { _______________________________________________ Mono-patches maillist - Mono-patches@lists.ximian.com http://lists.ximian.com/mailman/listinfo/mono-patches