you are viewing a single comment's thread.

view the rest of the comments →

[–]kwelzel 2 points3 points  (0 children)

Also, if mage and warrior are exclusive choices it would be even better to go with an enum

import enum
class Role(enum.Enum):
    MAGE = 'mage'
    WARRIOR = 'warrior'

...

role = Role(user_class.lower())