MCPcopy
hub / github.com/junegunn/fzf / parseGetParams

Function parseGetParams

src/server.go:259–277  ·  view source on GitHub ↗
(query string)

Source from the content-addressed store, hash-verified

257}
258
259func parseGetParams(query string) getParams {
260 params := getParams{limit: 100, offset: 0}
261 for _, pair := range strings.Split(query, "&") {
262 parts := strings.SplitN(pair, "=", 2)
263 if len(parts) == 2 {
264 switch parts[0] {
265 case "limit", "offset":
266 if val, err := strconv.Atoi(parts[1]); err == nil {
267 if parts[0] == "limit" {
268 params.limit = val
269 } else {
270 params.offset = val
271 }
272 }
273 }
274 }
275 }
276 return params
277}

Callers 1

handleHttpRequestMethod · 0.85

Calls

no outgoing calls

Tested by

no test coverage detected

Used in the wild real call sites across dependent graphs

searching dependent graphs…