set response headers correctly for successful searches