Little profile refactoring and favorite server adding fix.
Done some refactoring on profiles handling. Too small, but deserve these two lines in commit. Fixed favorite server addition from scratch.
This commit is contained in:
2
cache/cache_profiles.go
vendored
2
cache/cache_profiles.go
vendored
@@ -47,8 +47,8 @@ func (c *Cache) deleteProfile(data map[string]string) {
|
||||
_, ok1 := c.Profiles[data["profile_name"]]
|
||||
c.ProfilesMutex.Unlock()
|
||||
if !ok1 {
|
||||
fmt.Println("Profile deleted")
|
||||
Database.Db.MustExec(Database.Db.Rebind("DELETE FROM urt_profiles WHERE name=?"), data["profile_name"])
|
||||
fmt.Println("Profile deleted")
|
||||
} else {
|
||||
fmt.Println("Something goes wrong! Profile is still here!")
|
||||
}
|
||||
|
Reference in New Issue
Block a user