MCPcopy Create free account
hub / github.com/1Panel-dev/1Panel / clampToInt

Function clampToInt

agent/app/service/recycle_bin.go:478–486  ·  view source on GitHub ↗
(v int64)

Source from the content-addressed store, hash-verified

476}
477
478func clampToInt(v int64) int {
479 if v > math.MaxInt {
480 return math.MaxInt
481 }
482 if v < math.MinInt {
483 return math.MinInt
484 }
485 return int(v)
486}
487
488func getRecycleBinDTOFromName(filename string) (*response.RecycleBinDTO, error) {
489 matches := re.GetRegex(re.RecycleBinFilePattern).FindStringSubmatch(filename)

Callers 2

buildTrashDTOFunction · 0.85
trashInfoToDTOFunction · 0.85

Calls

no outgoing calls

Tested by

no test coverage detected