Skip to content

Commit c8bfd60

Browse files
committed
Fix missing Example::__toString method
This method is required by the Tag interface.
1 parent 45ada3e commit c8bfd60

File tree

1 file changed

+10
-0
lines changed

1 file changed

+10
-0
lines changed

src/DocBlock/Tags/Example.php

Lines changed: 10 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -134,6 +134,16 @@ public function setFileURI($uri)
134134
return $this;
135135
}
136136

137+
/**
138+
* Returns a string representation for this tag.
139+
*
140+
* @return string
141+
*/
142+
public function __toString()
143+
{
144+
return $this->filePath . ($this->description ? ' ' . $this->description->render() : '');
145+
}
146+
137147
/**
138148
* Returns true if the provided URI is relative or contains a complete scheme (and thus is absolute).
139149
*

0 commit comments

Comments
 (0)