JSON: Implemented proper containment check instead of nesting level check