Parcourir la source

Added roxbot's own version of arg parse

tags/v2.0.0
Roxie Gibson il y a 5 ans
Parent
révision
f49b6e94e0
1 fichiers modifiés avec 9 ajouts et 0 suppressions
  1. +9
    -0
      roxbot/utils.py

+ 9
- 0
roxbot/utils.py Voir le fichier

@@ -27,6 +27,15 @@ SOFTWARE.

import asyncio
import discord
import argparse


class ArgParser(argparse.ArgumentParser):
"""Create Roxbot's own version of ArgumentParser that doesn't exit the program on error."""
def error(self, message):
# By passing here, it will just continue in cases where a user inputs an arg that can't be parsed.
pass


class Menu:


Chargement…
Annuler
Enregistrer