diff options
Diffstat (limited to 'models/access.go')
-rw-r--r-- | models/access.go | 6 |
1 files changed, 6 insertions, 0 deletions
diff --git a/models/access.go b/models/access.go index 970f4a941f..749a2604d5 100644 --- a/models/access.go +++ b/models/access.go @@ -42,6 +42,12 @@ func UpdateAccess(access *Access) error { return err } +// DeleteAccess deletes access record. +func DeleteAccess(access *Access) error { + _, err := orm.Delete(access) + return err +} + // UpdateAccess updates access information with session for rolling back. func UpdateAccessWithSession(sess *xorm.Session, access *Access) error { if _, err := sess.Id(access.Id).Update(access); err != nil { |