From 8e6e0e9ad2fe535b28ab5ed0f8e5b9e127cde092 Mon Sep 17 00:00:00 2001 From: Chris Johnston Date: Sun, 21 Oct 2018 14:27:02 -0700 Subject: [PATCH] lint: Remove public setters for MessageApplication, MessageActivity properties (#1182) This fixes an error that was introduced in d30d12246d5173321c2556cf65d3c69da230cb8c (thanks Still for noticing!) Changes the public property setters of the MessageActivity and MessageApplication entities to be internal, since they cannot be modified by the user in the API. --- .../Entities/Messages/MessageActivity.cs | 4 ++-- .../Entities/Messages/MessageApplication.cs | 10 +++++----- 2 files changed, 7 insertions(+), 7 deletions(-) diff --git a/src/Discord.Net.Core/Entities/Messages/MessageActivity.cs b/src/Discord.Net.Core/Entities/Messages/MessageActivity.cs index d19e6a8e9..b539b8f9b 100644 --- a/src/Discord.Net.Core/Entities/Messages/MessageActivity.cs +++ b/src/Discord.Net.Core/Entities/Messages/MessageActivity.cs @@ -13,11 +13,11 @@ namespace Discord /// /// Gets the type of activity of this message. /// - public MessageActivityType Type { get; set; } + public MessageActivityType Type { get; internal set; } /// /// Gets the party ID of this activity, if any. /// - public string PartyId { get; set; } + public string PartyId { get; internal set; } private string DebuggerDisplay => $"{Type}{(string.IsNullOrWhiteSpace(PartyId) ? "" : $" {PartyId}")}"; diff --git a/src/Discord.Net.Core/Entities/Messages/MessageApplication.cs b/src/Discord.Net.Core/Entities/Messages/MessageApplication.cs index 960d1700f..05616cb59 100644 --- a/src/Discord.Net.Core/Entities/Messages/MessageApplication.cs +++ b/src/Discord.Net.Core/Entities/Messages/MessageApplication.cs @@ -13,19 +13,19 @@ namespace Discord /// /// Gets the snowflake ID of the application. /// - public ulong Id { get; set; } + public ulong Id { get; internal set; } /// /// Gets the ID of the embed's image asset. /// - public string CoverImage { get; set; } + public string CoverImage { get; internal set; } /// /// Gets the application's description. /// - public string Description { get; set; } + public string Description { get; internal set; } /// /// Gets the ID of the application's icon. /// - public string Icon { get; set; } + public string Icon { get; internal set; } /// /// Gets the Url of the application's icon. /// @@ -34,7 +34,7 @@ namespace Discord /// /// Gets the name of the application. /// - public string Name { get; set; } + public string Name { get; internal set; } private string DebuggerDisplay => $"{Name} ({Id}): {Description}"; public override string ToString()