|
From: Chris F. <cd...@fo...> - 2013-08-10 00:16:00
|
On Fri, Aug 09, 2013 at 11:17:35AM +0100, Mark Ellis wrote: > So, back to the caps conversion in the format plugin. It registers > caps_conv_evo3_to_xmlformat() as the converter, which essentially just > calls caps_conv_generic() with the contact objtype name. This objtype > seems somewhat artificial and forced, because we have no objtype > information at this time, the converter seems it should be objtype > neutral, it's only there because we have no caps info for other > objtypes. And that's where it goes wrong if the contacts objtype has > been disabled in the evo plugin. > > I'm thinking that this function should instead, check to see if oldcaps > has the objtypes we know about, in this case only contacts. If it > exists, create a new caps objtype and populate it. If it/they don't > exists, we haven't registered those objtypes, so just return TRUE, since > we haven't actually had an error, we just don't have caps info for the > other objtypes that have been registered by the plugin. That sounds reasonable to me. I think caps_conv_evo3_to_xmlformat() should loop through all the objformats in *oldcaps, and convert what it can, instead of hardcoding the "contacts" objtype. If you have the opportunity, it would be interesting to test whether an empty "events" objtype in **newcaps would result in null events being used in the sync. - Chris |