Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Contribute to GitLab
Sign in
Toggle navigation
L
laravel-mongodb
Project
Project
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
sinan
laravel-mongodb
Commits
c2818dc8
Commit
c2818dc8
authored
Apr 08, 2014
by
Jens Segers
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Move protected function to the bottom
parent
9ca3f159
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
18 additions
and
18 deletions
+18
-18
EmbedsMany.php
src/Jenssegers/Mongodb/Relations/EmbedsMany.php
+18
-18
No files found.
src/Jenssegers/Mongodb/Relations/EmbedsMany.php
View file @
c2818dc8
...
...
@@ -437,24 +437,6 @@ class EmbedsMany extends Relation {
return
count
(
$ids
);
}
/**
* Transform single ID, single Model or array of Models into an array of IDs
*
* @param mixed $ids
* @return array
*/
protected
function
getIdsArrayFrom
(
$ids
)
{
if
(
!
is_array
(
$ids
))
$ids
=
array
(
$ids
);
foreach
(
$ids
as
&
$id
)
{
if
(
$id
instanceof
Model
)
$id
=
$id
->
getKey
();
}
return
$ids
;
}
/**
* Delete alias.
*
...
...
@@ -477,6 +459,24 @@ class EmbedsMany extends Relation {
return
$this
->
save
(
$model
);
}
/**
* Transform single ID, single Model or array of Models into an array of IDs
*
* @param mixed $ids
* @return array
*/
protected
function
getIdsArrayFrom
(
$ids
)
{
if
(
!
is_array
(
$ids
))
$ids
=
array
(
$ids
);
foreach
(
$ids
as
&
$id
)
{
if
(
$id
instanceof
Model
)
$id
=
$id
->
getKey
();
}
return
$ids
;
}
/**
* Convert an array of embedded documents to a Collection.
*
...
...
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