default.go
func (r *Password) SetBSON(raw bson.Raw) error {
	var m bson.M
	if err := raw.Unmarshal(&m); err != nil {
		return err
	}

	if data, ok := m["data"].(string); ok {
		*r = Password(data)
		return nil
	}

	return errors.New("couldn't unmarshal bson raw value as Password")
}
func (r *Password) SetBSON(raw bson.Raw) error {
	var m bson.M
	if err := raw.Unmarshal(&m); err != nil {
		return err
	}

	if data, ok := m["data"].(string); ok {
		*r = Password(data)
		return nil
	}

	return errors.New("couldn't unmarshal bson raw value as Password")
}
// SetBSON sets the Password from raw bson data