fixing query lib