Skip to content

Commit 64d576c

Browse files
committed
feat: support Casbin UpdatableAdapter interface
1 parent 1fc9463 commit 64d576c

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

src/Adapters/DatabaseAdapter.php

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -222,7 +222,7 @@ public function updatePolicy(string $sec, string $ptype, array $oldRule, array $
222222
{
223223
$instance = $this->eloquent->where('p_type', $ptype);
224224
foreach($oldRule as $k => $v) {
225-
$instance->where($k, $v);
225+
$instance->where('v' . $k, $v);
226226
}
227227
$instance->first();
228228
$update = [];

0 commit comments

Comments
 (0)