Code
Hub
Workspaces
Following
Trending
Connect
MCP
copy
Create free account
hub
/
github.com/krau/SaveAny-Bot
/ DetectFileExt
Function
DetectFileExt
common/utils/fsutil/fs.go:27–33 ·
view source on GitHub ↗
(fp string)
Source
from the content-addressed store, hash-verified
25
}
26
27
func
DetectFileExt(fp string) string {
28
mt, err := mimetype.DetectFile(fp)
29
if
err != nil {
30
return
""
31
}
32
return
mt.Extension()
33
}
34
35
type
File
struct
{
36
*os.File
Callers
2
Execute
Method · 0.92
processElement
Method · 0.92
Calls
no outgoing calls
Tested by
no test coverage detected