refactor: consolidate debug flag and update gitignore

- Rename debugMode to isDebug for consistency across codebase
- Move debug flag check in ValidateTimeStamp to match other validations
- Add database.db to gitignore and remove unused config file
- Update README.md to clarify user registration rules
This commit is contained in:
2026-02-28 15:48:01 +08:00
parent b661118180
commit 686c3dcd4e
8 changed files with 32 additions and 27 deletions
+11 -8
View File
@@ -12,20 +12,22 @@ import (
)
type SoftwareInfo struct {
Name string
Version string
Developer string
BuildVer int16
Name string
Version string
Developer string
BuildVer int16
Description string
BuildType string
BuildType string
}
var isDebug bool
func main() {
softwareInfo := SoftwareInfo{
Name: "Super-frpc",
Version: "0.0.1",
Name: "Super-frpc",
Version: "0.0.1",
Developer: "Madobi Nanami",
BuildVer: 1,
BuildVer: 1,
BuildType: "debug",
}
postLog.Info(fmt.Sprintf("%s %s (Build %d.%s) by %s", softwareInfo.Name, softwareInfo.Version, softwareInfo.BuildVer, softwareInfo.BuildType, softwareInfo.Developer))
@@ -52,6 +54,7 @@ func main() {
// Initialize logger with debug mode
postLog.SetDebugMode(config.Debug)
isDebug = config.Debug
if err := InitDatabase(*dbPath); err != nil {
postLog.Fatal(fmt.Sprintf("Failed to initialize database: %v", err))