update condition about when to default to document query string
build file