mirror of
https://github.com/graphql-python/graphene.git
synced 2025-05-04 08:23:40 +03:00
decode
This commit is contained in:
parent
f2ac42d9e1
commit
c23ff11220
|
@ -27,9 +27,9 @@ def deprecated(reason):
|
||||||
|
|
||||||
def decorator(func1):
|
def decorator(func1):
|
||||||
if inspect.isclass(func1):
|
if inspect.isclass(func1):
|
||||||
fmt1 = f"Call to deprecated class {func1.__name__} ({reason!r})."
|
fmt1 = f"Call to deprecated class {func1.__name__} ({reason.decode()})."
|
||||||
else:
|
else:
|
||||||
fmt1 = f"Call to deprecated function {func1.__name__} ({reason!r})."
|
fmt1 = f"Call to deprecated function {func1.__name__} ({reason.decode()})."
|
||||||
|
|
||||||
@functools.wraps(func1)
|
@functools.wraps(func1)
|
||||||
def new_func1(*args, **kwargs):
|
def new_func1(*args, **kwargs):
|
||||||
|
|
Loading…
Reference in New Issue
Block a user