Browse Source

lint: rename IsStream to IsStreaming

While it might be more proper to refer to a voice state as composing
a stream (i.e., the IVoiceState is a Stream), this property is ported
up most often to actual user entities. It makes more sense to
communicate that the user is streaming, rather than stating that the
user itself is a stream.

This is also more gramatically consistent with the other voice state
properties (e.g., IsMuted). Movement from noun-form to participle-form
remains inline with the past-participle form used on the other
properties.
pull/1376/head
Christopher Felegy 5 years ago
parent
commit
dcd9cdd13e
No known key found for this signature in database GPG Key ID: 3AB2CA980DDC61A9
8 changed files with 8 additions and 8 deletions
  1. +1
    -1
      src/Discord.Net.Core/Entities/Users/IVoiceState.cs
  2. +1
    -1
      src/Discord.Net.Rest/Entities/Users/RestGroupUser.cs
  3. +1
    -1
      src/Discord.Net.Rest/Entities/Users/RestGuildUser.cs
  4. +1
    -1
      src/Discord.Net.Rest/Entities/Users/RestWebhookUser.cs
  5. +1
    -1
      src/Discord.Net.WebSocket/Entities/Users/SocketGroupUser.cs
  6. +1
    -1
      src/Discord.Net.WebSocket/Entities/Users/SocketGuildUser.cs
  7. +1
    -1
      src/Discord.Net.WebSocket/Entities/Users/SocketVoiceState.cs
  8. +1
    -1
      src/Discord.Net.WebSocket/Entities/Users/SocketWebhookUser.cs

+ 1
- 1
src/Discord.Net.Core/Entities/Users/IVoiceState.cs View File

@@ -61,6 +61,6 @@ namespace Discord
/// <returns>
/// <c>true</c> if the user is streaming; otherwise <c>false</c>.
/// </returns>
bool IsStream { get; }
bool IsStreaming { get; }
}
}

+ 1
- 1
src/Discord.Net.Rest/Entities/Users/RestGroupUser.cs View File

@@ -36,6 +36,6 @@ namespace Discord.Rest
/// <inheritdoc />
string IVoiceState.VoiceSessionId => null;
/// <inheritdoc />
bool IVoiceState.IsStream => false;
bool IVoiceState.IsStreaming => false;
}
}

+ 1
- 1
src/Discord.Net.Rest/Entities/Users/RestGuildUser.cs View File

@@ -152,6 +152,6 @@ namespace Discord.Rest
/// <inheritdoc />
string IVoiceState.VoiceSessionId => null;
/// <inheritdoc />
bool IVoiceState.IsStream => false;
bool IVoiceState.IsStreaming => false;
}
}

+ 1
- 1
src/Discord.Net.Rest/Entities/Users/RestWebhookUser.cs View File

@@ -96,6 +96,6 @@ namespace Discord.Rest
/// <inheritdoc />
string IVoiceState.VoiceSessionId => null;
/// <inheritdoc />
bool IVoiceState.IsStream => false;
bool IVoiceState.IsStreaming => false;
}
}

+ 1
- 1
src/Discord.Net.WebSocket/Entities/Users/SocketGroupUser.cs View File

@@ -62,6 +62,6 @@ namespace Discord.WebSocket
/// <inheritdoc />
string IVoiceState.VoiceSessionId => null;
/// <inheritdoc />
bool IVoiceState.IsStream => false;
bool IVoiceState.IsStreaming => false;
}
}

+ 1
- 1
src/Discord.Net.WebSocket/Entities/Users/SocketGuildUser.cs View File

@@ -55,7 +55,7 @@ namespace Discord.WebSocket
/// <inheritdoc />
public bool IsMuted => VoiceState?.IsMuted ?? false;
/// <inheritdoc />
public bool IsStream => VoiceState?.IsStream ?? false;
public bool IsStreaming => VoiceState?.IsStreaming ?? false;
/// <inheritdoc />
public DateTimeOffset? JoinedAt => DateTimeUtils.FromTicks(_joinedAtTicks);
/// <summary>


+ 1
- 1
src/Discord.Net.WebSocket/Entities/Users/SocketVoiceState.cs View File

@@ -47,7 +47,7 @@ namespace Discord.WebSocket
/// <inheritdoc />
public bool IsSelfDeafened => (_voiceStates & Flags.SelfDeafened) != 0;
/// <inheritdoc />
public bool IsStream => (_voiceStates & Flags.SelfStream) != 0;
public bool IsStreaming => (_voiceStates & Flags.SelfStream) != 0;

internal SocketVoiceState(SocketVoiceChannel voiceChannel, string sessionId, bool isSelfMuted, bool isSelfDeafened, bool isMuted, bool isDeafened, bool isSuppressed, bool isStream)
{


+ 1
- 1
src/Discord.Net.WebSocket/Entities/Users/SocketWebhookUser.cs View File

@@ -115,6 +115,6 @@ namespace Discord.WebSocket
/// <inheritdoc />
string IVoiceState.VoiceSessionId => null;
/// <inheritdoc />
bool IVoiceState.IsStream => false;
bool IVoiceState.IsStreaming => false;
}
}

Loading…
Cancel
Save