diff --git a/src/jobservice/replication/transfer.go b/src/jobservice/replication/transfer.go index 5bd5d9593..69cdc37c6 100644 --- a/src/jobservice/replication/transfer.go +++ b/src/jobservice/replication/transfer.go @@ -183,8 +183,8 @@ func (c *Checker) Enter() (string, error) { func (c *Checker) enter() (string, error) { project, err := getProject(c.project) if err != nil { - c.logger.Infof("failed to get project %s from %s: %v", c.project, c.srcURL, err) - return "", nil + c.logger.Errorf("failed to get project %s from %s: %v", c.project, c.srcURL, err) + return "", err } err = c.createProject(project) @@ -232,7 +232,7 @@ func getProject(name string) (*models.Project, error) { } list := []*models.Project{} - if err = json.Unmarshal(data, list); err != nil { + if err = json.Unmarshal(data, &list); err != nil { return nil, err } diff --git a/src/ui/router.go b/src/ui/router.go index d4a0e7b6b..6a45e05ef 100644 --- a/src/ui/router.go +++ b/src/ui/router.go @@ -40,10 +40,10 @@ func initRouters() { beego.Router("/harbor/sign-up", &controllers.IndexController{}) beego.Router("/harbor/dashboard", &controllers.IndexController{}) beego.Router("/harbor/projects", &controllers.IndexController{}) - beego.Router("/harbor/projects/:id/repository", &controllers.IndexController{}) - beego.Router("/harbor/projects/:id/replication", &controllers.IndexController{}) - beego.Router("/harbor/projects/:id/member", &controllers.IndexController{}) - beego.Router("/harbor/projects/:id/log", &controllers.IndexController{}) + beego.Router("/harbor/projects/:id/repositories", &controllers.IndexController{}) + beego.Router("/harbor/projects/:id/replications", &controllers.IndexController{}) + beego.Router("/harbor/projects/:id/members", &controllers.IndexController{}) + beego.Router("/harbor/projects/:id/logs", &controllers.IndexController{}) beego.Router("/harbor/tags/:id/*", &controllers.IndexController{}) beego.Router("/harbor/users", &controllers.IndexController{})