Use with_metaclass from future.utils for python3 compat.

This commit is contained in:
Ahmed Charles 2015-10-23 02:02:43 +00:00 committed by Griatch
parent 79437c0e48
commit 8a66fc40a9
11 changed files with 21 additions and 26 deletions

View file

@ -8,6 +8,7 @@ All commands in Evennia inherit from the 'Command' class in this module.
import re
from evennia.locks.lockhandler import LockHandler
from evennia.utils.utils import is_iter, fill, lazy_property
from future.utils import with_metaclass
def _init_command(mcs, **kwargs):
@ -87,7 +88,7 @@ class CommandMeta(type):
# parsing errors.
class Command(object):
class Command(with_metaclass(CommandMeta, object)):
"""
Base command
@ -127,8 +128,6 @@ class Command(object):
system to create the help entry for the command, so it's a good idea to
format it similar to this one)
"""
# Tie our metaclass, for some convenience cleanup
__metaclass__ = CommandMeta
# the main way to call this command (e.g. 'look')
key = "command"