package utils import ( "github.com/jinzhu/copier" ) // copy a by b b->a func CopyStructFields(a interface{}, b interface{}, fields ...string) (err error) { return copier.Copy(a, b) }