Fix race condition, introduced in the previous commit

This commit is contained in:
ErickSkrauch
2019-06-19 00:56:09 +03:00
parent 5b4761e4e5
commit f872fe4698
3 changed files with 5 additions and 2 deletions

View File

@@ -51,11 +51,13 @@ var serveCmd = &cobra.Command{
return
}
texturesStorage := queue.CreateInMemoryTexturesStorage()
texturesStorage.Start()
mojangTexturesQueue := &queue.JobsQueue{
Logger: logger,
Storage: &queue.SplittedStorage{
UuidsStorage: mojangUuidsRepository,
TexturesStorage: queue.CreateInMemoryTexturesStorage(),
TexturesStorage: texturesStorage,
},
}
logger.Info("Mojang's textures queue is successfully initialized")