Skip to content
This repository was archived by the owner on Mar 29, 2024. It is now read-only.

Commit 25f6c8f

Browse files
committed
Add typehint for $value param in Template::set(), closes #36
1 parent 058effe commit 25f6c8f

File tree

1 file changed

+5
-5
lines changed

1 file changed

+5
-5
lines changed

stubs/src/Template.php

Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -42,13 +42,13 @@ public function getIsolate(): Isolate
4242
/**
4343
* Adds a property to each instance created by this template.
4444
*
45-
* @param NameValue $name
46-
* @param PrimitiveValue|Template $value
47-
* @param int $attributes One of \v8\PropertyAttribute constants
45+
* @param NameValue $name
46+
* @param Data|PrimitiveValue|Template $value
47+
* @param int $attributes One of \V8\PropertyAttribute constants
4848
*
4949
* @return void
5050
*/
51-
public function set(NameValue $name, /*Data*/ $value, int $attributes = PropertyAttribute::None)
51+
public function set(NameValue $name, Data $value, int $attributes = PropertyAttribute::None)
5252
{
5353
}
5454

@@ -77,8 +77,8 @@ public function setAccessorProperty(
7777
* @param NameValue $name The name of the property for which an accessor is added.
7878
*
7979
* @param callable $getter The callback to invoke when getting the property.
80-
*
8180
* Callback signature should be (NameValue $property, PropertyCallbackInfo $info)
81+
*
8282
* @param callable $setter The callback to invoke when setting the property.
8383
* Callback signature should be (NameValue $property, PropertyCallbackInfo $info)
8484
*

0 commit comments

Comments
 (0)