Unify maximum edit distance across fuzzy and match query to `max_edits`

Closes #2565