fixed bug related to id extraction