Skip to content

Commit

Permalink
persons: fix mef persons suppression problem
Browse files Browse the repository at this point in the history
* Firx mef person index suppression problem when a document is deleted
* Closes #601

Co-Authored-by: Renaud Michotte <[email protected]>
  • Loading branch information
zannkukai committed Nov 18, 2019
1 parent f9a2c1f commit 6d6984b
Showing 1 changed file with 4 additions and 0 deletions.
4 changes: 4 additions & 0 deletions rero_ils/modules/indexer_utils.py
Original file line number Diff line number Diff line change
Expand Up @@ -41,6 41,10 @@ def record_to_index(record):
# put all document in the same index
if re.search(r'/documents/', schema):
schema = re.sub(r'-.*\.json', '.json', schema)
# authorities specific transformation
if re.search(r'/authorities/', schema):
schema = re.sub(r'/authorities/', '/persons/', schema)
schema = re.sub(r'mef-person', 'mef_person', schema)
index, doc_type = schema_to_index(schema, index_names=index_names)

if index and doc_type:
Expand Down

0 comments on commit 6d6984b

Please sign in to comment.