|
1 | 1 | from abc import ABC, abstractmethod |
2 | | -from .database_types import TemporalType, FractionalType, ColType_UUID, Boolean, ColType, String_UUID, JSONType |
| 2 | +from .database_types import TemporalType, FractionalType, ColType_UUID, Boolean, ColType, String_UUID, JSON |
3 | 3 | from .compiler import Compilable |
4 | 4 |
|
5 | 5 |
|
@@ -49,7 +49,7 @@ def normalize_uuid(self, value: str, coltype: ColType_UUID) -> str: |
49 | 49 | return f"TRIM({value})" |
50 | 50 | return self.to_string(value) |
51 | 51 |
|
52 | | - def normalize_json(self, value: str, _coltype: JSONType) -> str: |
| 52 | + def normalize_json(self, value: str, _coltype: JSON) -> str: |
53 | 53 | """Creates an SQL expression, that converts 'value' to its minified json string representation.""" |
54 | 54 | raise NotImplementedError() |
55 | 55 |
|
@@ -77,7 +77,7 @@ def normalize_value_by_type(self, value: str, coltype: ColType) -> str: |
77 | 77 | return self.normalize_uuid(value, coltype) |
78 | 78 | elif isinstance(coltype, Boolean): |
79 | 79 | return self.normalize_boolean(value, coltype) |
80 | | - elif isinstance(coltype, JSONType): |
| 80 | + elif isinstance(coltype, JSON): |
81 | 81 | return self.normalize_json(value, coltype) |
82 | 82 | return self.to_string(value) |
83 | 83 |
|
|
0 commit comments