diff --git a/README.md b/README.md index effade4..a2e20a6 100644 --- a/README.md +++ b/README.md @@ -15,16 +15,17 @@ Once [installed](#install), you can use the following code to read a file from your S3 file storage: ```php -$loop = React\EventLoop\Factory::create(); -$browser = new React\Http\Browser($loop); +read('example.txt')->then(function (string $contents) { echo $contents; +}, function (Exception $e) { + echo 'Error: ' . $e->getMessage() . PHP_EOL; }); - -$loop->run(); ``` ## Install