Skip to content

Commit

Permalink
pylint: Fix use-dict-literal
Browse files Browse the repository at this point in the history
Pylint 2.10 introduced new checker:
> Emitted when using dict() to create an empty dictionary instead of the
  literal {}. The literal is faster as it avoids an additional function
  call.

See pylint-dev/pylint#4365

Fixes: #279
Signed-off-by: Stanislav Levin <slev@altlinux.org>
  • Loading branch information
stanislavlevin authored and olivergs committed Mar 3, 2022
1 parent e2f772f commit 090f109
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion tests/directorymock.py
Expand Up @@ -125,4 +125,4 @@ def get_profiles(self):

def get_profile(self, cn):
logging.debug("Directory Mock: Getting profile %s", cn)
return self.data.profiles.get(cn, dict())
return self.data.profiles.get(cn, {})

0 comments on commit 090f109

Please sign in to comment.