mirror of
https://github.com/Hopiu/django-watson.git
synced 2026-03-16 22:00:22 +00:00
Attempting to fix a unicode error
This commit is contained in:
parent
76fba4c171
commit
ebb9b1d704
1 changed files with 2 additions and 1 deletions
|
|
@ -9,6 +9,7 @@ from django.db.models import get_model
|
|||
from django.contrib import admin
|
||||
from django.contrib.contenttypes.models import ContentType
|
||||
from django.db import transaction
|
||||
from django.utils.encoding import force_text
|
||||
|
||||
from watson.registration import SearchEngine, _bulk_save_search_entries
|
||||
from watson.models import SearchEntry
|
||||
|
|
@ -38,7 +39,7 @@ def rebuild_index_for_model(model_, engine_slug_, verbosity_):
|
|||
if verbosity_ >= 3:
|
||||
print("Refreshed search entry for {model} {obj} in {engine_slug!r} search engine.".format(
|
||||
model = model_._meta.verbose_name,
|
||||
obj = obj,
|
||||
obj = force_text(obj),
|
||||
engine_slug = engine_slug_,
|
||||
))
|
||||
if verbosity_ == 2:
|
||||
|
|
|
|||
Loading…
Reference in a new issue