Skip to content

Commit 24bc274

Browse files
chore: fixed srb linting errors
1 parent 1c84b17 commit 24bc274

File tree

1 file changed

+3
-3
lines changed

1 file changed

+3
-3
lines changed

lib/stream-chat/client.rb

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -689,7 +689,7 @@ def delete_channels(cids, hard_delete: false)
689689
# Revoke tokens for an application issued since the given date.
690690
sig { params(before: T.any(DateTime, String)).returns(StreamChat::StreamResponse) }
691691
def revoke_tokens(before)
692-
before = T.cast(before, DateTime).rfc3339 if before.instance_of?(DateTime)
692+
before = before.rfc3339 if before.instance_of?(DateTime)
693693
update_app_settings({ 'revoke_tokens_issued_before' => before })
694694
end
695695

@@ -702,7 +702,7 @@ def revoke_user_token(user_id, before)
702702
# Revoke tokens for users issued since.
703703
sig { params(user_ids: T::Array[String], before: T.any(DateTime, String)).returns(StreamChat::StreamResponse) }
704704
def revoke_users_token(user_ids, before)
705-
before = T.cast(before, DateTime).rfc3339 if before.instance_of?(DateTime)
705+
before = before.rfc3339 if before.instance_of?(DateTime)
706706

707707
updates = []
708708
user_ids.map do |user_id|
@@ -948,7 +948,7 @@ def query_threads(filter, sort: nil, **options)
948948
sig { params(message_id: String, user_id: String, remind_at: T.nilable(DateTime)).returns(StreamChat::StreamResponse) }
949949
def create_reminder(message_id, user_id, remind_at = nil)
950950
data = { user_id: user_id }
951-
data[:remind_at] = T.cast(remind_at, DateTime).rfc3339 if remind_at.instance_of?(DateTime)
951+
data[:remind_at] = remind_at.rfc3339 if remind_at.instance_of?(DateTime)
952952
post("messages/#{message_id}/reminders", data: data)
953953
end
954954

0 commit comments

Comments
 (0)