File tree Expand file tree Collapse file tree 2 files changed +2
-4
lines changed
exist-core/src/main/java/org/exist/xquery/value Expand file tree Collapse file tree 2 files changed +2
-4
lines changed Original file line number Diff line number Diff line change @@ -146,8 +146,7 @@ public Object toJavaObject() throws XPathException {
146
146
@ Override
147
147
public void destroy (final XQueryContext context , final Sequence contextSequence ) {
148
148
// do not close if this object is part of the contextSequence
149
- if (contextSequence == this ||
150
- (contextSequence instanceof ValueSequence && ((ValueSequence ) contextSequence ).containsValue (this ))) {
149
+ if (contextSequence == this || contextSequence .containsReference (this )) {
151
150
return ;
152
151
}
153
152
try {
Original file line number Diff line number Diff line change @@ -121,8 +121,7 @@ public void close() throws IOException {
121
121
@ Override
122
122
public void destroy (XQueryContext context , final Sequence contextSequence ) {
123
123
// do not close if this object is part of the contextSequence
124
- if (contextSequence == this
125
- || (contextSequence instanceof ValueSequence && ((ValueSequence ) contextSequence ).containsValue (this ))) {
124
+ if (contextSequence == this || contextSequence .containsReference (this )) {
126
125
return ;
127
126
}
128
127
LOG .debug ("Closing input stream" );
You can’t perform that action at this time.
0 commit comments