public static bool HasAttribute(this XElement element, string name) { return element.Attribute(name) != null; }