tBKwtWS 8 жил өмнө
parent
commit
28c299ac8c
1 өөрчлөгдсөн 8 нэмэгдсэн , 0 устгасан
  1. 8 0
      common/userstatus.py

+ 8 - 0
common/userstatus.py

@@ -1,3 +1,11 @@
+def atleast_admin(self, user, channel):
+    if channel not in self.channels:
+        return False
+    if self.channels[channel].is_owner(user) or self.channels[channel].is_admin(user):
+        return True
+    else:
+        return False
+        
 def atleast_oper(self, user, channel):
     if channel not in self.channels:
         return False