Skip to content

Commit c61a1ab

Browse files
committed
fix: for Enforcer pass FilteredAdapter will load all policy
Signed-off-by: rong fengliang <[email protected]>
1 parent be38837 commit c61a1ab

File tree

1 file changed

+2
-1
lines changed

1 file changed

+2
-1
lines changed

src/main/java/org/casbin/jcasbin/main/Enforcer.java

+2-1
Original file line numberDiff line numberDiff line change
@@ -71,7 +71,8 @@ public Enforcer(Model m, Adapter adapter) {
7171

7272
initialize();
7373

74-
if (this.adapter != null) {
74+
// fix: Enforcer pass FilteredAdapter will load all policy
75+
if (this.adapter != null && !isFiltered()) {
7576
loadPolicy();
7677
}
7778
}

0 commit comments

Comments
 (0)