docs: added a note about running migrations (#2875)
* docs: added a note about running migrations * docs: fixed link
This commit is contained in:
@@ -10,8 +10,20 @@ Version `1.7.0` of Medusa introduces a breaking change in the [CustomerService](
|
||||
|
||||
In this new version, the method [`retrieveByEmail` in the Customer Service](../../../references/services/classes/CustomerService.md#retrievebyemail) has been deprecated in favor of other methods. Read the actions required below to learn which methods to use instead.
|
||||
|
||||
In addition, after introducing the Claim Order feature, this version of Medusa introduces changes in the database that allows two customers having the same email based on the value of the `has_account` field. This change requires running migrations after the update.
|
||||
|
||||
## Actions Required
|
||||
|
||||
### Run Migrations
|
||||
|
||||
Run the following command to run migrations:
|
||||
|
||||
```bash
|
||||
medusa migrations run
|
||||
```
|
||||
|
||||
### Change Used Methods
|
||||
|
||||
Instead of using `customerService.retrieveByEmail`, you should now use the methods `customerService.retrieveRegisteredByEmail` or `customerService.retrieveUnRegisteredByEmail`.
|
||||
|
||||
The `customerService.retrieveRegisteredByEmail` method allows you to retrieve a registered customer by email:
|
||||
|
||||
Reference in New Issue
Block a user