given this is wrapped in a ``is_callable`` call, this could also put the element in the array directly, removing the need to define this private method ``registerSort``