mirror of
https://github.com/OrchardCMS/Orchard.git
synced 2025-04-05 21:01:35 +08:00
Fixing ObjectDumper duplicated attributes
--HG-- branch : dev
This commit is contained in:
parent
da189c2427
commit
526aa949bf
@ -68,20 +68,15 @@ namespace Orchard.DesignerTools.Services {
|
||||
}
|
||||
|
||||
private void DumpObject(object o, string name) {
|
||||
if (_parents.Count >= _levels) {
|
||||
_node.Add(
|
||||
new XElement("div", new XAttribute("class", "name"), name),
|
||||
new XElement("div", new XAttribute("class", "object last"), o)
|
||||
);
|
||||
|
||||
return;
|
||||
}
|
||||
|
||||
_node.Add(
|
||||
new XElement("div", new XAttribute("class", "name"), name),
|
||||
new XElement("div", new XAttribute("class", "type"), FormatType(o.GetType()))
|
||||
);
|
||||
|
||||
if (_parents.Count >= _levels) {
|
||||
return;
|
||||
}
|
||||
|
||||
if (o is IDictionary) {
|
||||
DumpDictionary((IDictionary)o);
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user