Thanks to visit codestin.com
Credit goes to github.com

Skip to content

Commit 1363f26

Browse files
committed
Minor refactoring
1 parent 834be1e commit 1363f26

1 file changed

Lines changed: 1 addition & 1 deletion

File tree

lib/core/common.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -2978,7 +2978,7 @@ def isAdminFromPrivileges(privileges):
29782978
# In Firebird there is no specific privilege that means
29792979
# that the user is DBA
29802980
# TODO: confirm
2981-
retVal |= (Backend.isDbms(DBMS.FIREBIRD) and "SELECT" in privileges and "INSERT" in privileges and "UPDATE" in privileges and "DELETE" in privileges and "REFERENCES" in privileges and "EXECUTE" in privileges)
2981+
retVal |= (Backend.isDbms(DBMS.FIREBIRD) and all(_ in privileges for _ in ("SELECT", "INSERT", "UPDATE", "DELETE", "REFERENCES", "EXECUTE")))
29822982

29832983
return retVal
29842984

0 commit comments

Comments
 (0)