summaryrefslogtreecommitdiff
path: root/cmd2
diff options
context:
space:
mode:
authorKevin Van Brunt <kmvanbrunt@gmail.com>2020-07-17 16:01:54 -0400
committerKevin Van Brunt <kmvanbrunt@gmail.com>2020-07-17 16:01:54 -0400
commitb0b825d0cdc0e38b48477719c608a065692f413d (patch)
treee5aa0adc686bc2841b60edc9eefc288752e0d7a6 /cmd2
parentfa9277157c32b527350eaef74e82515064b4bc5e (diff)
downloadcmd2-git-b0b825d0cdc0e38b48477719c608a065692f413d.tar.gz
Fixed hook documentation
Diffstat (limited to 'cmd2')
-rw-r--r--cmd2/cmd2.py8
1 files changed, 4 insertions, 4 deletions
diff --git a/cmd2/cmd2.py b/cmd2/cmd2.py
index 65047cc8..cdee3523 100644
--- a/cmd2/cmd2.py
+++ b/cmd2/cmd2.py
@@ -4281,11 +4281,11 @@ class Cmd(cmd.Cmd):
signature = inspect.signature(func)
_, param = list(signature.parameters.items())[0]
if param.annotation != plugin.CommandFinalizationData:
- raise TypeError("{} must have one parameter declared with type "
- "'cmd2.plugin.CommandFinalizationData'".format(func.__name__))
+ raise TypeError("{} must have one parameter declared with type {}".format(func.__name__,
+ plugin.CommandFinalizationData))
if signature.return_annotation != plugin.CommandFinalizationData:
- raise TypeError("{} must declare return a return type of "
- "'cmd2.plugin.CommandFinalizationData'".format(func.__name__))
+ raise TypeError("{} must declare return a return type of {}".format(func.__name__,
+ plugin.CommandFinalizationData))
def register_cmdfinalization_hook(self, func: Callable[[plugin.CommandFinalizationData],
plugin.CommandFinalizationData]) -> None: