aboutsummaryrefslogtreecommitdiffstats
path: root/pydis_site/apps/api/serializers.py
diff options
context:
space:
mode:
authorGravatar Hassan Abouelela <[email protected]>2022-01-31 00:42:55 +0400
committerGravatar Hassan Abouelela <[email protected]>2022-01-31 00:45:32 +0400
commit77a2b731c1b7132ab56a7f27ac665e4d71e0d169 (patch)
tree0c371647c53f249b769d5e2d1e0688cf472ff261 /pydis_site/apps/api/serializers.py
parentRevert ugly deploy preview redirect hack. (diff)
parentMerge pull request #649 from python-discord/update-pyfakefs (diff)
Merge branch 'main' into swfarnsworth/smarter-resources/merge-with-main
Signed-off-by: Hassan Abouelela <[email protected]> # Conflicts: # poetry.lock # pyproject.toml
Diffstat (limited to 'pydis_site/apps/api/serializers.py')
-rw-r--r--pydis_site/apps/api/serializers.py2
1 files changed, 1 insertions, 1 deletions
diff --git a/pydis_site/apps/api/serializers.py b/pydis_site/apps/api/serializers.py
index ac05ebd4..4a702d61 100644
--- a/pydis_site/apps/api/serializers.py
+++ b/pydis_site/apps/api/serializers.py
@@ -177,7 +177,7 @@ class InfractionSerializer(ModelSerializer):
raise ValidationError({'expires_at': [f'{infr_type} infractions cannot expire.']})
hidden = attrs.get('hidden')
- if hidden and infr_type in ('superstar', 'warning', 'voice_ban'):
+ if hidden and infr_type in ('superstar', 'warning', 'voice_ban', 'voice_mute'):
raise ValidationError({'hidden': [f'{infr_type} infractions cannot be hidden.']})
if not hidden and infr_type in ('note', ):