(obj)
| 2286 | /* global: toDebugString: true */ |
| 2287 | |
| 2288 | function serializeObject(obj) { |
| 2289 | var seen = []; |
| 2290 | |
| 2291 | return JSON.stringify(obj, function(key, val) { |
| 2292 | val = toJsonReplacer(key, val); |
| 2293 | if (isObject(val)) { |
| 2294 | |
| 2295 | if (seen.indexOf(val) >= 0) return '...'; |
| 2296 | |
| 2297 | seen.push(val); |
| 2298 | } |
| 2299 | return val; |
| 2300 | }); |
| 2301 | } |
| 2302 | |
| 2303 | function toDebugString(obj) { |
| 2304 | if (typeof obj === 'function') { |
no test coverage detected