Skip to content

Commit d994b83

Browse files
committed
fix: code links
1 parent 29ecc0b commit d994b83

File tree

3 files changed

+9
-9
lines changed

3 files changed

+9
-9
lines changed

core/data-persisters.md

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -22,7 +22,7 @@ persist data for a given resource will be used.
2222

2323
## Creating a Custom Data Persister
2424

25-
To create a data persister, you have to implement the [`ContextAwareDataPersisterInterface`](https://github.com/api-platform/core/blob/main/src/DataPersister/ContextAwareDataPersisterInterface.php).
25+
To create a data persister, you have to implement the [`ContextAwareDataPersisterInterface`](https://github.com/api-platform/core/blob/2.6/src/DataPersister/ContextAwareDataPersisterInterface.php).
2626
This interface defines only 3 methods:
2727

2828
* `persist`: to create or update the given data
@@ -71,7 +71,7 @@ services:
7171
#tags: [ 'api_platform.data_persister' ]
7272
```
7373

74-
Note that if you don't need any `$context` in your data persister's methods, you can implement the [`DataPersisterInterface`](https://github.com/api-platform/core/blob/main/src/DataPersister/DataPersisterInterface.php) instead.
74+
Note that if you don't need any `$context` in your data persister's methods, you can implement the [`DataPersisterInterface`](https://github.com/api-platform/core/blob/2.6/src/DataPersister/DataPersisterInterface.php) instead.
7575

7676
## Decorating the Built-In Data Persisters
7777

core/data-providers.md

Lines changed: 6 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -13,23 +13,23 @@ retrieve data for a given resource will be used.
1313

1414
For a given resource, you can implement two kinds of interface:
1515

16-
* the [`CollectionDataProviderInterface`](https://github.com/api-platform/core/blob/main/src/Core/DataProvider/CollectionDataProviderInterface.php)
16+
* the [`CollectionDataProviderInterface`](https://github.com/api-platform/core/blob/2.6/src/DataProvider/CollectionDataProviderInterface.php)
1717
is used when fetching a collection.
18-
* the [`ItemDataProviderInterface`](https://github.com/api-platform/core/blob/main/src/Core/DataProvider/ItemDataProviderInterface.php)
18+
* the [`ItemDataProviderInterface`](https://github.com/api-platform/core/blob/2.6/src/DataProvider/ItemDataProviderInterface.php)
1919
is used when fetching items.
2020

2121
Both implementations can also implement a third, optional, interface called
22-
['RestrictedDataProviderInterface'](https://github.com/api-platform/core/blob/main/src/Core/DataProvider/RestrictedDataProviderInterface.php)
22+
['RestrictedDataProviderInterface'](https://github.com/api-platform/core/blob/2.6/src/DataProvider/RestrictedDataProviderInterface.php)
2323
if you want to limit their effects to a single resource or operation.
2424

2525
In the following examples we will create custom data providers for an entity class called `App\Entity\BlogPost`.
2626
Note, that if your entity is not Doctrine-related, you need to flag the identifier property by using `#[ApiProperty(identifier: true)` for things to work properly (see also [Entity Identifier Case](serialization.md#entity-identifier-case)).
2727

2828
## Custom Collection Data Provider
2929

30-
First, your `BlogPostCollectionDataProvider` has to implement the [`CollectionDataProviderInterface`](https://github.com/api-platform/core/blob/main/src/Core/DataProvider/CollectionDataProviderInterface.php):
30+
First, your `BlogPostCollectionDataProvider` has to implement the [`CollectionDataProviderInterface`](https://github.com/api-platform/core/blob/2.6/src/DataProvider/CollectionDataProviderInterface.php):
3131

32-
The `getCollection` method must return an `array`, a `Traversable` or a [`ApiPlatform\Core\DataProvider\PaginatorInterface`](https://github.com/api-platform/core/blob/main/src/Core/DataProvider/PaginatorInterface.php) instance.
32+
The `getCollection` method must return an `array`, a `Traversable` or a [`ApiPlatform\Core\DataProvider\PaginatorInterface`](https://github.com/api-platform/core/blob/2.6/src/DataProvider/PaginatorInterface.php) instance.
3333
If no data is available, you should return an empty array.
3434

3535
```php
@@ -79,7 +79,7 @@ You can find a full working example in the [API Platform's demo application](htt
7979

8080
## Custom Item Data Provider
8181

82-
The process is similar for item data providers. Create a `BlogPostItemDataProvider` implementing the [`ItemDataProviderInterface`](https://github.com/api-platform/core/blob/main/src/Core/DataProvider/ItemDataProviderInterface.php)
82+
The process is similar for item data providers. Create a `BlogPostItemDataProvider` implementing the [`ItemDataProviderInterface`](https://github.com/api-platform/core/blob/2.6/src/DataProvider/ItemDataProviderInterface.php)
8383
interface:
8484

8585
The `getItem` method can return `null` if no result has been found.

core/openapi.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -474,7 +474,7 @@ As described [in the Symfony documentation](https://symfony.com/doc/current/temp
474474
</html>
475475
```
476476

477-
You may want to copy the [one shipped with API Platform](https://github.com/api-platform/core/blob/main/src/Bridge/Symfony/Bundle/Resources/views/SwaggerUi/index.html.twig) and customize it.
477+
You may want to copy the [one shipped with API Platform](https://github.com/api-platform/core/blob/2.6/src/Bridge/Symfony/Bundle/Resources/views/SwaggerUi/index.html.twig) and customize it.
478478

479479
## Compatibility Layer with Amazon API Gateway
480480

0 commit comments

Comments
 (0)