Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
[FIX] registry: check if index exists before logging
The `update_db_index` method is called even if the field has no index (the check on `index` field attribute is here on purpose). Before 13f02a6 was applied, the call of `sql.drop_index` was taking care of the index existence if a `IF EXISTS` SQL statement, so even if the field had no index it wasn't causing any issue. With 13f02a6 applied, the log 'Keep unexpected index' is spam even if the field has actually no index at all in the database. This commit ensures to check the existence of the index before logging. closes #75387 Signed-off-by: Xavier Morel (xmo) <xmo@odoo.com>
- Loading branch information