aboutsummaryrefslogtreecommitdiffstats
path: root/pydis_site/utils
diff options
context:
space:
mode:
authorGravatar sco1 <[email protected]>2019-09-18 15:46:36 -0700
committerGravatar sco1 <[email protected]>2019-09-18 15:46:36 -0700
commit609d6c0a48170e8eeefca2c6f0fd55c014c7ad65 (patch)
treecf46bf8da7478207f008c0af31005e39f0a691e3 /pydis_site/utils
parentUpdate dependencies & relock (diff)
Update linting rules & partially relint
Diffstat (limited to 'pydis_site/utils')
-rw-r--r--pydis_site/utils/resources.py6
1 files changed, 4 insertions, 2 deletions
diff --git a/pydis_site/utils/resources.py b/pydis_site/utils/resources.py
index fb5faef8..637fd785 100644
--- a/pydis_site/utils/resources.py
+++ b/pydis_site/utils/resources.py
@@ -30,7 +30,8 @@ class Resource:
return f"<Resource name={self.name}>"
@classmethod
- def construct_from_yaml(cls, yaml_data: typing.TextIO) -> Resource: # noqa
+ def construct_from_yaml(cls, yaml_data: typing.TextIO) -> Resource:
+ """Construct a Resource object from the provided YAML."""
resource = cls()
loaded = yaml.safe_load(yaml_data)
@@ -57,7 +58,8 @@ class Category:
return f"<Category name={self.name}>"
@classmethod
- def construct_from_directory(cls, directory: str) -> Category: # noqa
+ def construct_from_directory(cls, directory: str) -> Category:
+ """Construct a Category object from the provided directory."""
category = cls()
with open(f"{directory}/_category_info.yaml") as category_info: