Commit 64b87412 by Michael DeHaan

Merge pull request #8139 from peterkh/devel

Fix "TypeError: group id must be integer" if groupid passed in for group key
parents ec874193 09a5d8f6
...@@ -440,7 +440,7 @@ class User(object): ...@@ -440,7 +440,7 @@ class User(object):
def group_exists(self,group): def group_exists(self,group):
try: try:
if group.isdigit(): if group.isdigit():
if grp.getgrgid(group): if grp.getgrgid(int(group)):
return True return True
else: else:
if grp.getgrnam(group): if grp.getgrnam(group):
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment