Skip to content

Commit f350cce

Browse files
committed
Change template typing
1 parent 9383329 commit f350cce

File tree

1 file changed

+3
-4
lines changed

1 file changed

+3
-4
lines changed

auto_labeling_pipeline/mappings.py

Lines changed: 3 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
import json
22
import pathlib
3-
from typing import Any, Dict, Optional, Type
3+
from typing import Any, Dict, Type
44

55
from jinja2 import Template
66

@@ -13,11 +13,10 @@ class MappingTemplate:
1313
label_collection: Type[Labels]
1414
template_file: str = ''
1515

16-
def __init__(self, label_collection: Type[Labels] = Labels, template: Optional[str] = ''):
16+
def __init__(self, label_collection: Type[Labels] = Labels, template: str = ''):
1717
if self.template_file:
1818
template = self.load()
19-
if template:
20-
self.template = template
19+
self.template = template
2120
if label_collection is not Labels:
2221
self.label_collection = label_collection
2322

0 commit comments

Comments
 (0)