summaryrefslogtreecommitdiff
path: root/src/SMAPI.Web/Framework
diff options
context:
space:
mode:
Diffstat (limited to 'src/SMAPI.Web/Framework')
-rw-r--r--src/SMAPI.Web/Framework/Clients/Pastebin/PasteInfo.cs2
-rw-r--r--src/SMAPI.Web/Framework/Clients/Pastebin/SavePasteResult.cs15
-rw-r--r--src/SMAPI.Web/Framework/ConfigModels/MongoDbConfig.cs6
3 files changed, 6 insertions, 17 deletions
diff --git a/src/SMAPI.Web/Framework/Clients/Pastebin/PasteInfo.cs b/src/SMAPI.Web/Framework/Clients/Pastebin/PasteInfo.cs
index 1ef3ef12..813ea115 100644
--- a/src/SMAPI.Web/Framework/Clients/Pastebin/PasteInfo.cs
+++ b/src/SMAPI.Web/Framework/Clients/Pastebin/PasteInfo.cs
@@ -1,5 +1,3 @@
-using System;
-
namespace StardewModdingAPI.Web.Framework.Clients.Pastebin
{
/// <summary>The response for a get-paste request.</summary>
diff --git a/src/SMAPI.Web/Framework/Clients/Pastebin/SavePasteResult.cs b/src/SMAPI.Web/Framework/Clients/Pastebin/SavePasteResult.cs
deleted file mode 100644
index 89dab697..00000000
--- a/src/SMAPI.Web/Framework/Clients/Pastebin/SavePasteResult.cs
+++ /dev/null
@@ -1,15 +0,0 @@
-namespace StardewModdingAPI.Web.Framework.Clients.Pastebin
-{
- /// <summary>The response for a save-log request.</summary>
- internal class SavePasteResult
- {
- /// <summary>Whether the log was successfully saved.</summary>
- public bool Success { get; set; }
-
- /// <summary>The saved paste ID (if <see cref="Success"/> is <c>true</c>).</summary>
- public string ID { get; set; }
-
- /// <summary>The error message (if saving failed).</summary>
- public string Error { get; set; }
- }
-}
diff --git a/src/SMAPI.Web/Framework/ConfigModels/MongoDbConfig.cs b/src/SMAPI.Web/Framework/ConfigModels/MongoDbConfig.cs
index 3c508300..e2e18477 100644
--- a/src/SMAPI.Web/Framework/ConfigModels/MongoDbConfig.cs
+++ b/src/SMAPI.Web/Framework/ConfigModels/MongoDbConfig.cs
@@ -24,6 +24,12 @@ namespace StardewModdingAPI.Web.Framework.ConfigModels
/*********
** Public method
*********/
+ /// <summary>Get whether a MongoDB instance is configured.</summary>
+ public bool IsConfigured()
+ {
+ return !string.IsNullOrWhiteSpace(this.Host);
+ }
+
/// <summary>Get the MongoDB connection string.</summary>
public string GetConnectionString()
{