mirror of
				https://github.com/elyby/chrly.git
				synced 2025-05-31 14:11:51 +05:30 
			
		
		
		
	Really fix usernames cache hit events
This commit is contained in:
		| @@ -40,9 +40,9 @@ func (s *StatsReporter) ConfigureWithDispatcher(d Subscriber) { | ||||
| 		} | ||||
|  | ||||
| 		if uuid == "" { | ||||
| 			s.IncCounter("mojang_textures:usernames:cache_hit_nil", 1) | ||||
| 			s.IncCounter("mojang_textures.usernames.cache_hit_nil", 1) | ||||
| 		} else { | ||||
| 			s.IncCounter("mojang_textures:usernames:cache_hit", 1) | ||||
| 			s.IncCounter("mojang_textures.usernames.cache_hit", 1) | ||||
| 		} | ||||
| 	}) | ||||
| 	d.Subscribe("mojang_textures:textures:after_cache", func(uuid string, textures *mojang.SignedTexturesResponse, err error) { | ||||
|   | ||||
| @@ -228,7 +228,7 @@ var statsReporterTestCases = []*StatsReporterTestCase{ | ||||
| 			{"mojang_textures:usernames:after_cache", "username", "", true, nil}, | ||||
| 		}, | ||||
| 		ExpectedCalls: [][]interface{}{ | ||||
| 			{"IncCounter", "mojang_textures:usernames:cache_hit_nil", int64(1)}, | ||||
| 			{"IncCounter", "mojang_textures.usernames.cache_hit_nil", int64(1)}, | ||||
| 		}, | ||||
| 	}, | ||||
| 	{ | ||||
| @@ -236,7 +236,7 @@ var statsReporterTestCases = []*StatsReporterTestCase{ | ||||
| 			{"mojang_textures:usernames:after_cache", "username", "aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa", true, nil}, | ||||
| 		}, | ||||
| 		ExpectedCalls: [][]interface{}{ | ||||
| 			{"IncCounter", "mojang_textures:usernames:cache_hit", int64(1)}, | ||||
| 			{"IncCounter", "mojang_textures.usernames.cache_hit", int64(1)}, | ||||
| 		}, | ||||
| 	}, | ||||
| 	{ | ||||
|   | ||||
		Reference in New Issue
	
	Block a user