Upgrading clean code

This commit is contained in:
Rafael Vargas
2022-07-10 14:27:40 -03:00
parent 7e9a6d45c0
commit c826af229c
7 changed files with 25 additions and 28 deletions

View File

@@ -3,7 +3,7 @@ from discord.ext.commands import Context
from discord import Client
from Controllers.AbstractController import AbstractController
from Controllers.ControllerResponse import ControllerResponse
from Exceptions.Exceptions import BadCommandUsage, Error, ErrorRemoving, InvalidInput, NumberRequired, UnknownError
from Exceptions.Exceptions import BadCommandUsage, VulkanError, ErrorRemoving, InvalidInput, NumberRequired
class RemoveController(AbstractController):
@@ -38,7 +38,7 @@ class RemoveController(AbstractController):
embed = self.embeds.ERROR_REMOVING()
return ControllerResponse(self.ctx, embed, error)
def __validate_input(self, position: str) -> Union[Error, None]:
def __validate_input(self, position: str) -> Union[VulkanError, None]:
try:
position = int(position)
except: