Skip to content

Commit 338e3d5

Browse files
committed
use isempty() to check whether the collection is empty or not
1 parent 272f3d3 commit 338e3d5

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

src/main/java/org/apache/ibatis/session/defaults/DefaultSqlSession.java

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -269,7 +269,7 @@ public void close() {
269269
}
270270

271271
private void closeCursors() {
272-
if (cursorList != null && cursorList.size() != 0) {
272+
if (cursorList != null && !cursorList.isEmpty()) {
273273
for (Cursor<?> cursor : cursorList) {
274274
try {
275275
cursor.close();

0 commit comments

Comments
 (0)