Skip to content

Commit 297fc12

Browse files
committed
Add special handling for :getMore command
1 parent 6b03686 commit 297fc12

File tree

1 file changed

+8
-1
lines changed

1 file changed

+8
-1
lines changed

lib/mongo.ex

Lines changed: 8 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1547,7 +1547,14 @@ defmodule Mongo do
15471547
|> Enum.at(0)
15481548

15491549
{_, params} = Keyword.pop_first(cmd, command)
1550-
collection = Keyword.get(cmd, command)
1550+
1551+
{collection, params} = case command do
1552+
:getMore ->
1553+
Keyword.pop_first(params, :collection)
1554+
1555+
_other ->
1556+
{Keyword.get(cmd, command), params}
1557+
end
15511558

15521559
collection =
15531560
case is_binary(collection) do

0 commit comments

Comments
 (0)