Refactor GetAccessLevel to include address parameter, update all ACL implementations and handlers for enhanced contextual access control.

This commit is contained in:
2025-09-08 07:42:47 +01:00
parent 85d806b157
commit c9314bdbd0
7 changed files with 12 additions and 14 deletions

View File

@@ -28,10 +28,10 @@ func (s *S) Configure(cfg ...any) (err error) {
return err
}
func (s *S) GetAccessLevel(pub []byte) (level string) {
func (s *S) GetAccessLevel(pub []byte, address string) (level string) {
for _, i := range s.ACL {
if i.Type() == s.Active.Load() {
level = i.GetAccessLevel(pub)
level = i.GetAccessLevel(pub, address)
break
}
}