Skip to content

Commit 21d8220

Browse files
committed
Added legacy methods for compat
1 parent 247da41 commit 21d8220

File tree

1 file changed

+48
-0
lines changed

1 file changed

+48
-0
lines changed

src/Node.php

+48
Original file line numberDiff line numberDiff line change
@@ -17,6 +17,54 @@ class Node extends Model
1717

1818
const PARENT_ID = NestedSet::PARENT_ID;
1919

20+
/**
21+
* @param Node $parent
22+
*
23+
* @return $this
24+
*
25+
* @deprecated since 4.1
26+
*/
27+
public function appendTo(self $parent)
28+
{
29+
return $this->appendToNode($parent);
30+
}
31+
32+
/**
33+
* @param Node $parent
34+
*
35+
* @return $this
36+
*
37+
* @deprecated since 4.1
38+
*/
39+
public function prependTo(self $parent)
40+
{
41+
return $this->prependToNode($parent);
42+
}
43+
44+
/**
45+
* @param Node $node
46+
*
47+
* @return bool
48+
*
49+
* @deprecated since 4.1
50+
*/
51+
public function insertBefore(self $node)
52+
{
53+
return $this->insertBeforeNode($node);
54+
}
55+
56+
/**
57+
* @param Node $node
58+
*
59+
* @return bool
60+
*
61+
* @deprecated since 4.1
62+
*/
63+
public function insertAfter(self $node)
64+
{
65+
return $this->insertAfterNode($node);
66+
}
67+
2068
/**
2169
* @return string
2270
*/

0 commit comments

Comments
 (0)