Skip to content

Commit

Permalink
Merge pull request #197 from rongfengliang/master
Browse files Browse the repository at this point in the history
fix: for Enforcer pass FilteredAdapter will load all policy
  • Loading branch information
hsluoyz authored Jun 12, 2021
2 parents 63f6f29 + c61a1ab commit f52df3d
Showing 1 changed file with 2 additions and 1 deletion.
3 changes: 2 additions & 1 deletion src/main/java/org/casbin/jcasbin/main/Enforcer.java
Original file line number Diff line number Diff line change
Expand Up @@ -72,7 +72,8 @@ public Enforcer(Model m, Adapter adapter) {

initialize();

if (this.adapter != null) {
// fix: Enforcer pass FilteredAdapter will load all policy
if (this.adapter != null && !isFiltered()) {
loadPolicy();
}
}
Expand Down

0 comments on commit f52df3d

Please sign in to comment.