Skip to content

Commit

Permalink
Add a missing code block about re-adding alias
Browse files Browse the repository at this point in the history
  • Loading branch information
bocharsky-bw committed Feb 8, 2021
1 parent 69d5f3f commit 2b4868e
Showing 1 changed file with 15 additions and 4 deletions.
19 changes: 15 additions & 4 deletions sfcasts/uploads/flysystem-usage.md
Expand Up @@ -60,10 +60,21 @@ php bin/console doctrine:fixtures:load
> `__construct()` references `FilesystemInterface` but no such service exists.
There are two ways to fix this. First, we could re-add the `alias` option and
point it at this `FilesystemInterface`. *Or*, we can create a new bind. I'll do
the second, because it works better if you have multiple filesystem services, which
we will soon. First, rename the argument to be more descriptive, how about
`$publicUploadFilesystem`.
point it at this `FilesystemInterface`:

```php
# config/packages/oneup_flysystem.yaml
oneup_flysystem:
# ...
filesystems:
public_uploads_filesystem:
adapter: public_uploads_adapter
alias: League\Flysystem\Filesystem
```

*Or*, we can create a new bind. I'll do the second, because it works better
if you have multiple filesystem services, which we will soon. First, rename
the argument to be more descriptive, how about `$publicUploadFilesystem`:

[[[ code('43bca769f7') ]]]

Expand Down

0 comments on commit 2b4868e

Please sign in to comment.