sort resources according to order specified by SSZ