|
@@ -1571,16 +1571,14 @@ func (s *Session) ChannelInvites(channelID string) (st []*Invite, err error) {
|
|
|
|
|
|
// ChannelInviteCreate creates a new invite for the given channel.
|
|
|
// channelID : The ID of a Channel
|
|
|
-// i : An Invite struct with the values MaxAge, MaxUses, Temporary,
|
|
|
-// and XkcdPass defined.
|
|
|
+// i : An Invite struct with the values MaxAge, MaxUses and Temporary defined.
|
|
|
func (s *Session) ChannelInviteCreate(channelID string, i Invite) (st *Invite, err error) {
|
|
|
|
|
|
data := struct {
|
|
|
MaxAge int `json:"max_age"`
|
|
|
MaxUses int `json:"max_uses"`
|
|
|
Temporary bool `json:"temporary"`
|
|
|
- XKCDPass string `json:"xkcdpass"`
|
|
|
- }{i.MaxAge, i.MaxUses, i.Temporary, i.XkcdPass}
|
|
|
+ }{i.MaxAge, i.MaxUses, i.Temporary}
|
|
|
|
|
|
body, err := s.RequestWithBucketID("POST", EndpointChannelInvites(channelID), data, EndpointChannelInvites(channelID))
|
|
|
if err != nil {
|
|
@@ -1620,7 +1618,7 @@ func (s *Session) ChannelPermissionDelete(channelID, targetID string) (err error
|
|
|
// ------------------------------------------------------------------------------------------------
|
|
|
|
|
|
// Invite returns an Invite structure of the given invite
|
|
|
-// inviteID : The invite code (or maybe xkcdpass?)
|
|
|
+// inviteID : The invite code
|
|
|
func (s *Session) Invite(inviteID string) (st *Invite, err error) {
|
|
|
|
|
|
body, err := s.RequestWithBucketID("GET", EndpointInvite(inviteID), nil, EndpointInvite(""))
|
|
@@ -1633,7 +1631,7 @@ func (s *Session) Invite(inviteID string) (st *Invite, err error) {
|
|
|
}
|
|
|
|
|
|
// InviteDelete deletes an existing invite
|
|
|
-// inviteID : the code (or maybe xkcdpass?) of an invite
|
|
|
+// inviteID : the code of an invite
|
|
|
func (s *Session) InviteDelete(inviteID string) (st *Invite, err error) {
|
|
|
|
|
|
body, err := s.RequestWithBucketID("DELETE", EndpointInvite(inviteID), nil, EndpointInvite(""))
|
|
@@ -1646,7 +1644,7 @@ func (s *Session) InviteDelete(inviteID string) (st *Invite, err error) {
|
|
|
}
|
|
|
|
|
|
// InviteAccept accepts an Invite to a Guild or Channel
|
|
|
-// inviteID : The invite code (or maybe xkcdpass?)
|
|
|
+// inviteID : The invite code
|
|
|
func (s *Session) InviteAccept(inviteID string) (st *Invite, err error) {
|
|
|
|
|
|
body, err := s.RequestWithBucketID("POST", EndpointInvite(inviteID), nil, EndpointInvite(""))
|