mirror of
https://github.com/cryptonote-social/csminer.git
synced 2024-09-11 05:35:23 +03:00
make sure pool username and logged in username match when getting stats
This commit is contained in:
parent
faea137ff2
commit
f56eae1134
@ -458,6 +458,13 @@ func GetMiningState() *GetMiningStateResponse {
|
||||
isMining = true
|
||||
}
|
||||
s, _, _ := stats.GetSnapshot(isMining)
|
||||
if plArgs == nil {
|
||||
s.PoolUsername = ""
|
||||
s.SecondsOld = -1.0
|
||||
} else if plArgs.Username != s.PoolUsername {
|
||||
s.PoolUsername = plArgs.Username
|
||||
s.SecondsOld = -1.0
|
||||
}
|
||||
configMutex.Lock()
|
||||
defer configMutex.Unlock()
|
||||
return &GetMiningStateResponse{
|
||||
|
Loading…
Reference in New Issue
Block a user