diff --git a/README.md b/README.md index 36f3b99..4ac1aee 100644 --- a/README.md +++ b/README.md @@ -41,7 +41,7 @@ public class ApplicationRole : MongoIdentityRole } } ``` -The `Id` field is automatically set at instantiation, this also applies to users inheriting from `MongoIdentityUser`, where a random integer is assigned to the `Id`. It is however not advised to rely on such random mechanism to set the primary key of your document. Using documents inheriting from `MongoIdentityRole` and `MongoIdentityUser` is recommended. +The `Id` field is automatically set at instantiation, this also applies to users inheriting from `MongoIdentityUser`, where a random integer is assigned to the `Id`. It is however not advised to rely on such random mechanism to set the primary key of your document. Using documents inheriting from `MongoIdentityRole` and `MongoIdentityUser`, which both use the `Guid` type for primary keys, is recommended. To add the stores, you can use the `IdentityBuilder` extension like so: @@ -55,7 +55,8 @@ services.AddIdentity() .AddDefaultTokenProviders(); ``` -It is also possible to share a common `IMongoDbContext` across your services: + +It is also possible to share a common `IMongoDbContext` across your services (requires https://www.nuget.org/packages/MongoDbGenericRepository/): ```csharp var mongoDbContext = new MongoDbContext("mongodb://localhost:27017", "MongoDbTests");