Skip to content

Commit 181261e

Browse files
committed
code example fixed
1 parent 4380e90 commit 181261e

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

README.md

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -36,7 +36,7 @@ $array[] = 'a';
3636
$array = new TypedArray('int', [1, 'a', 3, 4]);
3737

3838
//correct, only Foo class instances passed to constructor.
39-
$array = new TypedObjectArray(Foo::class, [
39+
$array = new TypedArray(Foo::class, [
4040
new Foo(),
4141
new Foo()
4242
]);
@@ -48,7 +48,7 @@ $array[] = new Foo();
4848
$array[] = new Bar();
4949

5050
//throw InvalidArgumentException, mixed array of instances passed to constructor.
51-
$array = new TypedObjectArray(Foo::class, [
51+
$array = new TypedArray(Foo::class, [
5252
new Foo(),
5353
new Bar()
5454
]);

0 commit comments

Comments
 (0)