Cleanup sorted_index_key method