Permalink
Browse files

Merge pull request #56 from SailingYYC/patch-1

MongoDB::Cursor::hint() requires ordered hashes.
  • Loading branch information...
2 parents e990505 + 58bcf89 commit a0eb7c59399ef5e83016734e7a72d16ebe62a41b @friedo friedo committed Feb 1, 2013
Showing with 1 addition and 1 deletion.
  1. +1 −1 lib/MongoDB/Cursor.pm
View
@@ -408,7 +408,7 @@ sub hint {
confess "cannot set hint after querying"
if $self->started_iterating;
confess 'not a hash reference'
- unless ref $index eq 'HASH';
+ unless ref $index eq 'HASH' || ref $index eq 'Tie::IxHash';
$self->_ensure_special;
$self->_query->{'$hint'} = $index;

0 comments on commit a0eb7c5

Please sign in to comment.