mirror of https://github.com/django/django.git
Refs #28459 -- Used default date converter on SQLite for better performance.
See https://docs.python.org/3/library/sqlite3.html#default-adapters-and-converters.
This commit is contained in:
parent
ae6fa914aa
commit
51ae4e1f32
|
@ -14,9 +14,7 @@ from django.db import utils
|
|||
from django.db.backends import utils as backend_utils
|
||||
from django.db.backends.base.base import BaseDatabaseWrapper
|
||||
from django.utils import timezone
|
||||
from django.utils.dateparse import (
|
||||
parse_date, parse_datetime, parse_duration, parse_time,
|
||||
)
|
||||
from django.utils.dateparse import parse_datetime, parse_duration, parse_time
|
||||
from django.utils.duration import duration_microseconds
|
||||
|
||||
from .client import DatabaseClient # isort:skip
|
||||
|
@ -36,7 +34,6 @@ def decoder(conv_func):
|
|||
|
||||
Database.register_converter("bool", b'1'.__eq__)
|
||||
Database.register_converter("time", decoder(parse_time))
|
||||
Database.register_converter("date", decoder(parse_date))
|
||||
Database.register_converter("datetime", decoder(parse_datetime))
|
||||
Database.register_converter("timestamp", decoder(parse_datetime))
|
||||
Database.register_converter("TIMESTAMP", decoder(parse_datetime))
|
||||
|
|
Loading…
Reference in New Issue