Skip to content
Projects
Groups
Snippets
Help
This project
Loading...
Sign in / Register
Toggle navigation
Y
yii2
Project
Overview
Details
Activity
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
PSDI Army
yii2
Commits
0f7ded8f
Commit
0f7ded8f
authored
Nov 29, 2013
by
Paul Klimov
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Mongo query unit test fixed.
parent
37664fff
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
4 additions
and
3 deletions
+4
-3
Collection.php
extensions/mongo/Collection.php
+1
-1
Query.php
extensions/mongo/Query.php
+3
-2
No files found.
extensions/mongo/Collection.php
View file @
0f7ded8f
...
...
@@ -253,7 +253,7 @@ class Collection extends Object
$result
[]
=
$actualValue
;
}
else
{
$key
=
$this
->
normalizeConditionKeyword
(
$key
);
if
(
strncmp
(
'$'
,
$key
,
1
)
!==
0
&&
array_key_exists
(
0
,
$actualValue
))
{
if
(
strncmp
(
'$'
,
$key
,
1
)
!==
0
&&
is_array
(
$actualValue
)
&&
array_key_exists
(
0
,
$actualValue
))
{
// shortcut for IN condition
$result
[
$key
][
'$in'
]
=
$actualValue
;
}
else
{
...
...
extensions/mongo/Query.php
View file @
0f7ded8f
...
...
@@ -123,9 +123,10 @@ class Query extends Component implements QueryInterface
*/
protected
function
buildCursor
(
$db
=
null
)
{
$where
=
$this
->
where
;
if
(
!
is_array
(
$where
))
{
if
(
$this
->
where
===
null
)
{
$where
=
[];
}
else
{
$where
=
$this
->
where
;
}
$selectFields
=
[];
if
(
!
empty
(
$this
->
select
))
{
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment