diff options
author | AUTOMATIC1111 <16777216c@gmail.com> | 2023-09-09 07:31:56 +0000 |
---|---|---|
committer | GitHub <noreply@github.com> | 2023-09-09 07:31:56 +0000 |
commit | 924642331b13b73adbada3270a52cc5c7ae85ace (patch) | |
tree | dd15c7eccf1ef65d9da772c14c16f943766ac69d /modules/script_callbacks.py | |
parent | c9c457eda8dec414dc38e874691d1e2736d6dcbb (diff) | |
parent | b6c1a1bbbf29a3041025aa336f6f843ffd7c7d46 (diff) | |
download | stable-diffusion-webui-gfx803-924642331b13b73adbada3270a52cc5c7ae85ace.tar.gz stable-diffusion-webui-gfx803-924642331b13b73adbada3270a52cc5c7ae85ace.tar.bz2 stable-diffusion-webui-gfx803-924642331b13b73adbada3270a52cc5c7ae85ace.zip |
Merge pull request #12846 from a666/deprecated-types
Fix some deprecated types
Diffstat (limited to 'modules/script_callbacks.py')
-rw-r--r-- | modules/script_callbacks.py | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/modules/script_callbacks.py b/modules/script_callbacks.py index c99695eb..9ed7ad21 100644 --- a/modules/script_callbacks.py +++ b/modules/script_callbacks.py @@ -1,7 +1,7 @@ import inspect
import os
from collections import namedtuple
-from typing import Optional, Dict, Any
+from typing import Optional, Any
from fastapi import FastAPI
from gradio import Blocks
@@ -258,7 +258,7 @@ def image_grid_callback(params: ImageGridLoopParams): report_exception(c, 'image_grid')
-def infotext_pasted_callback(infotext: str, params: Dict[str, Any]):
+def infotext_pasted_callback(infotext: str, params: dict[str, Any]):
for c in callback_map['callbacks_infotext_pasted']:
try:
c.callback(infotext, params)
@@ -449,7 +449,7 @@ def on_infotext_pasted(callback): """register a function to be called before applying an infotext.
The callback is called with two arguments:
- infotext: str - raw infotext.
- - result: Dict[str, any] - parsed infotext parameters.
+ - result: dict[str, any] - parsed infotext parameters.
"""
add_callback(callback_map['callbacks_infotext_pasted'], callback)
|