Skip to content

Commit

Permalink
Fixed wrong method names in the doc blocks
Browse files Browse the repository at this point in the history
  • Loading branch information
zepich authored Jan 22, 2024
1 parent 1fd33ba commit 3faac28
Showing 1 changed file with 4 additions and 4 deletions.
8 changes: 4 additions & 4 deletions src/ZipStream.php
Original file line number Diff line number Diff line change
Expand Up @@ -59,7 +59,7 @@
*
* // read and add each file to the archive
* foreach ($files as $path)
* $zip->addFileFormPath(fileName: $path, $path);
* $zip->addFileFromPath(fileName: $path, $path);
*
* // write archive footer to stream
* $zip->finish();
Expand Down Expand Up @@ -293,7 +293,7 @@ public function addFile(
* // add a file named 'bigfile.rar' from the local file
* // '/usr/share/bigfile.rar' with a comment and a last-modified
* // time of two hours ago
* $zip->addFile(
* $zip->addFileFromPath(
* fileName: 'bigfile.rar',
* path: '/usr/share/bigfile.rar',
* comment: 'this is a comment about bigfile.rar',
Expand Down Expand Up @@ -494,7 +494,7 @@ public function addFileFromPsr7Stream(
*
* ```php
* foreach($files as $name => $size) {
* $archive->addFileFromPsr7Stream(
* $archive->addFileFromCallback(
* fileName: 'streamfile.txt',
* exactSize: $size,
* callback: function() use($name): Psr\Http\Message\StreamInterface {
Expand Down Expand Up @@ -629,7 +629,7 @@ public function addFileFromCallback(
*
* ```php
* // add a directory named 'world/'
* $zip->addFile(fileName: 'world/');
* $zip->addDirectory(fileName: 'world/');
* ```
*/
public function addDirectory(
Expand Down

0 comments on commit 3faac28

Please sign in to comment.