This repository was archived by the owner on Jan 24, 2024. It is now read-only.
File tree 3 files changed +4
-4
lines changed
source/NavigationBuilder/Services
3 files changed +4
-4
lines changed Original file line number Diff line number Diff line change @@ -29,7 +29,7 @@ public function hasLink($id): bool
29
29
*/
30
30
public function addLink (Link $ link )
31
31
{
32
- $ this ->links [$ link ->primaryKey ()] = $ link ;
32
+ $ this ->links [( string ) $ link ->primaryKey ()] = $ link ;
33
33
}
34
34
35
35
/**
@@ -69,7 +69,7 @@ public function hasTree($id): bool
69
69
*/
70
70
public function addTree (Tree $ tree )
71
71
{
72
- $ this ->tree [$ tree ->primaryKey ()] = $ tree ;
72
+ $ this ->tree [( string ) $ tree ->primaryKey ()] = $ tree ;
73
73
}
74
74
75
75
/**
Original file line number Diff line number Diff line change @@ -50,7 +50,7 @@ public function getList(): array
50
50
51
51
/** @var Link $link */
52
52
foreach ($ this ->source ->find () as $ link ) {
53
- $ output [$ link ->primaryKey ()] = $ this ->wrapper ->wrapLink ($ link );
53
+ $ output [( string ) $ link ->primaryKey ()] = $ this ->wrapper ->wrapLink ($ link );
54
54
}
55
55
56
56
return $ output ;
Original file line number Diff line number Diff line change @@ -13,7 +13,7 @@ class LinkWrapper
13
13
public function wrapLink (Link $ link ): array
14
14
{
15
15
return [
16
- 'id ' => $ link ->primaryKey (),
16
+ 'id ' => ( string ) $ link ->primaryKey (),
17
17
'text ' => $ link ->text ,
18
18
'href ' => $ link ->href ,
19
19
'attributes ' => $ link ->getAttributes (),
You can’t perform that action at this time.
0 commit comments