Skip to content
This repository has been archived by the owner on May 10, 2022. It is now read-only.

Commit

Permalink
Add method to remove a key from the config
Browse files Browse the repository at this point in the history
  • Loading branch information
Kai Sassnowski committed May 18, 2018
1 parent 92a0dcb commit 1e623b4
Showing 1 changed file with 7 additions and 0 deletions.
7 changes: 7 additions & 0 deletions config.py
Original file line number Diff line number Diff line change
Expand Up @@ -51,3 +51,10 @@ def get(key, default=None):
return default

return config[key]


def delete(key):
"""Removes a key from the config"""
config = _get_config()
del config[key]
write(config)

0 comments on commit 1e623b4

Please sign in to comment.