From f97de7979f918cea23aaf1e0985c3221c2556478 Mon Sep 17 00:00:00 2001 From: Hackerchai Date: Wed, 29 Jul 2020 15:44:15 +0800 Subject: [PATCH] Feat: update README.md --- README.md | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/README.md b/README.md index d06ab93..00e7a45 100644 --- a/README.md +++ b/README.md @@ -22,7 +22,7 @@ actix-rt = "1.1.1" 1. Using actix-casbin as actor alone ```rust -use actix_casbin::casbin::{DefaultModel, FileAdapter, Result}; +use actix_casbin::casbin::{DefaultModel, FileAdapter, Result, Enforcer}; use actix_casbin::{CasbinActor, CasbinCmd, CasbinResult}; #[actix_rt::main] @@ -56,9 +56,9 @@ async fn main() -> Result<()> { ``` 2. Use actix-casbin with casbin actix middleware [actix-casbin-auth](https://github.com/casbin-rs/actix-casbin-auth) ```rust +use actix_casbin::casbin::{DefaultModel, FileAdapter, Result, CachedEnforcer}; use actix_casbin::{CasbinActor, CasbinCmd, CasbinResult}; use actix_casbin_auth::CasbinService; -use casbin::prelude::*; #[actix_rt::main] async fn main() -> Result<()> {