── helpers ──────────────────────────────────────────────────────────────────
(s string)
| 1313 | // ── helpers ────────────────────────────────────────────────────────────────── |
| 1314 | |
| 1315 | func parseVMID(s string) (int, error) { |
| 1316 | vmid, err := strconv.Atoi(s) |
| 1317 | if err != nil || vmid <= 0 { |
| 1318 | return 0, fmt.Errorf("invalid VMID %q: must be a positive integer", s) |
| 1319 | } |
| 1320 | |
| 1321 | return vmid, nil |
| 1322 | } |
no outgoing calls
no test coverage detected