mirror of
https://github.com/spotiflacapp/SpotiFLAC-Mobile.git
synced 2026-06-01 03:15:17 +07:00
18 lines
342 B
Go
18 lines
342 B
Go
package backend
|
|
|
|
import (
|
|
"os"
|
|
"path/filepath"
|
|
)
|
|
|
|
func GetDefaultMusicPath() string {
|
|
// Get user's home directory
|
|
homeDir, err := os.UserHomeDir()
|
|
if err != nil {
|
|
// Fallback to Public Music if can't get home dir
|
|
return "C:\\Users\\Public\\Music"
|
|
}
|
|
|
|
// Return path to user's Music folder
|
|
return filepath.Join(homeDir, "Music")
|
|
}
|