Skip to content

Commit

Permalink
change the size of varchar in CasbinPolicy table (#5)
Browse files Browse the repository at this point in the history
  • Loading branch information
JunNishimura committed Mar 28, 2024
1 parent b0dac19 commit 692758a
Showing 1 changed file with 7 additions and 7 deletions.
14 changes: 7 additions & 7 deletions policy.go
Original file line number Diff line number Diff line change
Expand Up @@ -4,13 +4,13 @@ package casbinbunadapter
// https://casbin.org/docs/policy-storage#database-storage-format
type CasbinPolicy struct {
ID int64 `bun:"id,pk,autoincrement"`
PType string `bun:"ptype,type:varchar(255),notnull"`
V0 string `bun:"v0,type:varchar(255)"`
V1 string `bun:"v1,type:varchar(255)"`
V2 string `bun:"v2,type:varchar(255)"`
V3 string `bun:"v3,type:varchar(255)"`
V4 string `bun:"v4,type:varchar(255)"`
V5 string `bun:"v5,type:varchar(255)"`
PType string `bun:"ptype,type:varchar(100),notnull"`
V0 string `bun:"v0,type:varchar(100)"`
V1 string `bun:"v1,type:varchar(100)"`
V2 string `bun:"v2,type:varchar(100)"`
V3 string `bun:"v3,type:varchar(100)"`
V4 string `bun:"v4,type:varchar(100)"`
V5 string `bun:"v5,type:varchar(100)"`
}

func (c CasbinPolicy) toSlice() []string {
Expand Down

0 comments on commit 692758a

Please sign in to comment.