Fixed generate-query-string.