From 95c195baf42e8a74680a74acdc20c00bab7660eb Mon Sep 17 00:00:00 2001 From: Luke Shumaker Date: Sat, 18 Jun 2016 06:19:16 -0400 Subject: go back to using plain strings --- go/parabola_hackers/users.go.in | 12 ++++++------ 1 file changed, 6 insertions(+), 6 deletions(-) (limited to 'go/parabola_hackers/users.go.in') diff --git a/go/parabola_hackers/users.go.in b/go/parabola_hackers/users.go.in index edd8a59..e54de01 100644 --- a/go/parabola_hackers/users.go.in +++ b/go/parabola_hackers/users.go.in @@ -89,8 +89,8 @@ func parseUser(_data interface{}) (ret User, err error) { } else if str, isTyp := iface.(string); !isTyp { errs = append(errs, "\"username\" is not a string") } else { - ret.Passwd.Name = p.String(str) - ret.Passwd.HomeDir = p.String("/home/" + str) + ret.Passwd.Name = str + ret.Passwd.HomeDir = "/home/" + str } if iface, isSet := data["fullname"]; !isSet { @@ -98,7 +98,7 @@ func parseUser(_data interface{}) (ret User, err error) { } else if str, isTyp := iface.(string); !isTyp { errs = append(errs, "\"fullname\" is not a string") } else { - ret.Passwd.GECOS = p.String(str) + ret.Passwd.GECOS = str } if iface, isSet := data["shell"]; !isSet { @@ -106,7 +106,7 @@ func parseUser(_data interface{}) (ret User, err error) { } else if str, isTyp := iface.(string); !isTyp { errs = append(errs, "\"shell\" is not a string") } else { - ret.Passwd.Shell = p.String(str) + ret.Passwd.Shell = str } if iface, isSet := data["groups"]; !isSet { @@ -126,7 +126,7 @@ func parseUser(_data interface{}) (ret User, err error) { } } if !e { - ret.Groups = set2list(groups) + ret.Groups = Set2list(groups) } } } @@ -134,7 +134,7 @@ func parseUser(_data interface{}) (ret User, err error) { err = &yaml.TypeError{Errors: errs} } - ret.Passwd.PwHash = p.String("x") // look in shadow for the password hash + ret.Passwd.PwHash = string("x") // look in shadow for the password hash ret.Passwd.GID = -1 return -- cgit v1.2.3