fix: initialize mimetypes for tests

This commit is contained in:
Deluan 2020-02-04 20:44:54 -05:00
parent 28bad95e66
commit e5e35516d7
2 changed files with 2 additions and 3 deletions

View File

@ -1,8 +1,8 @@
package server
package consts
import "mime"
func initMimeTypes() {
func init() {
mt := map[string]string{
".mp3": "audio/mpeg",
".ogg": "audio/ogg",

View File

@ -23,7 +23,6 @@ type Server struct {
func New(scanner *scanner.Scanner, ds model.DataStore) *Server {
a := &Server{Scanner: scanner, ds: ds}
initMimeTypes()
initialSetup(ds)
a.initRoutes()
a.initScanner()