Skip to content

Commit

Permalink
Minor: remove empty sequence checks
Browse files Browse the repository at this point in the history
  • Loading branch information
Dominique Villard committed Mar 19, 2022
1 parent 19585d4 commit 9f76ec0
Show file tree
Hide file tree
Showing 3 changed files with 2 additions and 9 deletions.
7 changes: 0 additions & 7 deletions src/main/java/redis/clients/jedis/UnifiedJedis.java
Original file line number Diff line number Diff line change
Expand Up @@ -3923,9 +3923,6 @@ public boolean bfExists(String key, String item) {

@Override
public List<Boolean> bfMExists(String key, String... items) {
if (items.length == 0) {
return Collections.emptyList();
}
return executeCommand(commandObjects.bfMExists(key, items));
}

Expand Down Expand Up @@ -3981,13 +3978,9 @@ public boolean cfExists(String key, String item) {

@Override
public List<Boolean> cfMExists(String key, String... items) {
if (items.length == 0) {
return Collections.emptyList();
}
return executeCommand(commandObjects.cfMExists(key, items));
}


@Override
public boolean cfDel(String key, String item) {
return executeCommand(commandObjects.cfDel(key, item));
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -217,7 +217,7 @@ public void insertExpansion() {
assertEquals(20, insert.size());
}

@Test
@Test(expected = JedisDataException.class)
public void testNoItemMExists() {
assertEquals(Collections.emptyList(), client.bfMExists("simpleBloom"));
}
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -191,7 +191,7 @@ public void testExistsItemExists() {
assertEquals(Collections.singletonList(true), client.cfMExists("cuckoo17", "foo"));
}

@Test
@Test(expected = JedisDataException.class)
public void testNoItemMExists() {
assertEquals(Collections.emptyList(), client.cfMExists("cuckoo17"));
}
Expand Down

0 comments on commit 9f76ec0

Please sign in to comment.