This commit is contained in:
Eduard Urbach 2017-10-11 10:37:33 +02:00
parent 46a3715bae
commit 7892657362
3 changed files with 26 additions and 27 deletions

View File

@ -34,7 +34,6 @@ var jobs = map[string]time.Duration{
"twist": 2 * time.Hour,
"search-index": 2 * time.Hour,
"refresh-episodes": 10 * time.Hour,
"refresh-track-titles": 10 * time.Hour,
"refresh-osu": 12 * time.Hour,
"sync-anime": 12 * time.Hour,
"sync-shoboi": 24 * time.Hour,

View File

@ -24,14 +24,14 @@ func main() {
}
func sync(track *arn.SoundTrack) {
for _, media := range track.Media {
media.RefreshMetaData()
println(media.Service, media.Title)
}
// for _, media := range track.Media {
// media.RefreshMetaData()
// println(media.Service, media.Title)
// }
err := track.Save()
// err := track.Save()
if err != nil {
panic(err)
}
// if err != nil {
// panic(err)
// }
}

View File

@ -37,23 +37,23 @@ func TestRoutes(t *testing.T) {
func TestInterfaceImplementations(t *testing.T) {
// API interfaces
var creatable = reflect.TypeOf((*api.Creatable)(nil)).Elem()
var updatable = reflect.TypeOf((*api.Updatable)(nil)).Elem()
var editable = reflect.TypeOf((*api.Editable)(nil)).Elem()
var actionable = reflect.TypeOf((*api.Actionable)(nil)).Elem()
var collection = reflect.TypeOf((*api.Collection)(nil)).Elem()
// Required interface implementations
var interfaceImplementations = map[string][]reflect.Type{
"User": []reflect.Type{
updatable,
editable,
},
"Thread": []reflect.Type{
creatable,
updatable,
editable,
actionable,
},
"Post": []reflect.Type{
creatable,
updatable,
editable,
actionable,
},
"SoundTrack": []reflect.Type{