sync: Extract function that builds a theme from importer
This commit is contained in:
parent
536dc0eb6b
commit
682598fdbb
3 changed files with 87 additions and 74 deletions
|
@ -164,7 +164,7 @@ func createTheme(_ httprouter.Params, body []byte) (interface{}, error) {
|
|||
return nil, errors.New("Theme's name not filled")
|
||||
}
|
||||
|
||||
return fic.CreateTheme(ut.Name, ut.URLId, "", ut.Authors, ut.Intro, ut.Headline, ut.Image)
|
||||
return fic.CreateTheme(ut)
|
||||
}
|
||||
|
||||
func updateTheme(theme fic.Theme, body []byte) (interface{}, error) {
|
||||
|
|
Reference in a new issue