Skip to content

Commit c73cf58

Browse files
committed
Update types for 3.8.
1 parent 2bbdffd commit c73cf58

File tree

1 file changed

+4
-3
lines changed

1 file changed

+4
-3
lines changed

django_unicorn/management/commands/startunicorn.py

Lines changed: 4 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,7 @@
11
import os
22
import webbrowser
33
from pathlib import Path
4+
from typing import Dict
45

56
from django.apps import apps
67
from django.conf import settings
@@ -40,7 +41,7 @@ def add_arguments(self, parser):
4041
parser.add_argument("app_name", type=str)
4142
parser.add_argument("component_names", nargs="+", type=str, help="Names of components")
4243

43-
def check_initials_directories(self, app_directory: Path) -> (dict[str, Path], bool):
44+
def check_initials_directories(self, app_directory: Path) -> (Dict[str, Path], bool):
4445
"""
4546
Checks for directories existance and creates them if necessary.
4647
Returns a tuple containing a dictonary `components` and `templates`
@@ -81,7 +82,7 @@ def obtain_nested_path(self, component_name: str) -> (str, str):
8182

8283
return "/".join(nested_paths), component_name
8384

84-
def create_nested_directories(self, paths: dict[str, Path], nested_path: str) -> None:
85+
def create_nested_directories(self, paths: Dict[str, Path], nested_path: str) -> None:
8586
"""
8687
Creates the nested directories for the components and templates.
8788
"""
@@ -103,7 +104,7 @@ def create_nested_directories(self, paths: dict[str, Path], nested_path: str) ->
103104

104105
(component_path / "__init__.py").touch(exist_ok=True)
105106

106-
def create_component_and_template(self, paths: dict[str, Path], nested_path: str, component_name: str) -> None:
107+
def create_component_and_template(self, paths: Dict[str, Path], nested_path: str, component_name: str) -> None:
107108
"""
108109
Creates the component and template files.
109110
"""

0 commit comments

Comments
 (0)