i want to sort an array of objects having id each object using another array that only has the ids, for example:
object = [ {id: 2, name: carlos}, {id: 1, n