mirror of
https://github.com/django/django.git
synced 2025-10-23 21:59:11 +00:00
Fixed #24938 -- Added PostgreSQL trigram support.
This commit is contained in:
committed by
Tim Graham
parent
d7334b405f
commit
1962a96a30
@@ -5,12 +5,13 @@ from django.db import migrations
|
||||
|
||||
try:
|
||||
from django.contrib.postgres.operations import (
|
||||
CreateExtension, HStoreExtension, UnaccentExtension,
|
||||
CreateExtension, HStoreExtension, TrigramExtension, UnaccentExtension,
|
||||
)
|
||||
except ImportError:
|
||||
from django.test import mock
|
||||
CreateExtension = mock.Mock()
|
||||
HStoreExtension = mock.Mock()
|
||||
TrigramExtension = mock.Mock()
|
||||
UnaccentExtension = mock.Mock()
|
||||
|
||||
|
||||
@@ -21,5 +22,6 @@ class Migration(migrations.Migration):
|
||||
# dash in its name.
|
||||
CreateExtension('uuid-ossp'),
|
||||
HStoreExtension(),
|
||||
TrigramExtension(),
|
||||
UnaccentExtension(),
|
||||
]
|
||||
|
||||
Reference in New Issue
Block a user