Skip to content

Commit

Permalink
fix: test
Browse files Browse the repository at this point in the history
  • Loading branch information
totalimmersion committed Dec 7, 2023
1 parent 2ae17fe commit 61d1dfc
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 2 deletions.
2 changes: 1 addition & 1 deletion channel.go
Original file line number Diff line number Diff line change
Expand Up @@ -50,6 +50,7 @@ type Channel struct {
PinnedMessages []*Message `json:"pinned_messages"`
PendingMessages []*Message `json:"pending_messages"`
Read []*ChannelRead `json:"read"`
Hidden bool `json:"hidden"`

CreatedAt time.Time `json:"created_at"`
UpdatedAt time.Time `json:"updated_at"`
Expand Down Expand Up @@ -661,7 +662,6 @@ func (ch *Channel) hide(ctx context.Context, userID string, clearHistory bool) (

type CreateChannelResponse struct {
Channel *Channel
Hidden bool `json:"hidden,omitempty"`
*Response
}

Expand Down
2 changes: 1 addition & 1 deletion channel_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -100,7 +100,7 @@ func TestClient_CreateChannel(t *testing.T) {
opt(&options)
}
if options.HideForCreator {
assert.True(t, resp.Hidden, "hidden channel")
assert.True(t, channel.Hidden, "hidden channel")
}
assert.Equal(t, tt.userID, channel.CreatedBy.ID, "channel created by")
})
Expand Down

0 comments on commit 61d1dfc

Please sign in to comment.