From bd50e598b898525772bcc578d85e3bc11209a38c Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?K=C3=A9vin=20Chalet?= Date: Mon, 9 May 2016 17:32:17 +0200 Subject: [PATCH] Update README.md --- README.md | 12 ++++++++++-- 1 file changed, 10 insertions(+), 2 deletions(-) diff --git a/README.md b/README.md index 25da35ef..f05339a6 100644 --- a/README.md +++ b/README.md @@ -27,7 +27,7 @@ OpenIddict is based on **[ASP.NET Core Identity](https://github.com/aspnet/Ident OpenIddict fully supports the **code/implicit/hybrid flows** and the **client credentials/resource owner password grants**. For more information about these terms, please visit the **[OpenID website](http://openid.net/specs/openid-connect-core-1_0.html)** and read the **[OAuth2 specification](https://tools.ietf.org/html/rfc6749)**. -Note: OpenIddict uses **[EntityFramework 7](https://github.com/aspnet/EntityFramework)** by default, but you can also provide your own store. +Note: OpenIddict uses **[EntityFramework Core](https://github.com/aspnet/EntityFramework)** by default, but you can also provide your own store. -------------- @@ -101,13 +101,21 @@ public void Configure(IApplicationBuilder app) { - **Update your EntityFramework context to inherit from `OpenIddictContext`**: ```csharp -public class ApplicationDbContext : OpenIddictContext { } +public class ApplicationDbContext : OpenIddictContext { + public ApplicationDbContext(DbContextOptions options) + : base(options) { + } +} ``` > **Note:** although recommended, inheriting from `OpenIddictContext` is not mandatory. Alternatively, you can also create your own context and manually add the entity sets needed by OpenIddict: ```csharp public class ApplicationDbContext : IdentityDbContext { + public ApplicationDbContext(DbContextOptions options) + : base(options) { + } + public DbSet Applications { get; set; } } ```