refactor(notification-outbox): drop unused state from sandbox Notify fakes
This commit is contained in:
@@ -96,16 +96,9 @@ public class SandboxDatabaseHelper
|
||||
/// </summary>
|
||||
public class SandboxNotifyHelper
|
||||
{
|
||||
private readonly string _instanceName;
|
||||
|
||||
public SandboxNotifyHelper(string instanceName)
|
||||
{
|
||||
_instanceName = instanceName;
|
||||
}
|
||||
|
||||
/// <summary>Selects the notification list to send to.</summary>
|
||||
public SandboxNotifyTarget To(string listName) =>
|
||||
new(listName, _instanceName);
|
||||
new();
|
||||
|
||||
/// <summary>
|
||||
/// Queries the delivery status of a previously-sent notification. The
|
||||
@@ -123,13 +116,8 @@ public class SandboxNotifyHelper
|
||||
/// </summary>
|
||||
public class SandboxNotifyTarget
|
||||
{
|
||||
private readonly string _listName;
|
||||
private readonly string _instanceName;
|
||||
|
||||
internal SandboxNotifyTarget(string listName, string instanceName)
|
||||
internal SandboxNotifyTarget()
|
||||
{
|
||||
_listName = listName;
|
||||
_instanceName = instanceName;
|
||||
}
|
||||
|
||||
/// <summary>
|
||||
|
||||
@@ -80,7 +80,7 @@ public class SandboxInstanceContext
|
||||
_gateway = gateway;
|
||||
ExternalSystem = external ?? new SandboxExternalHelper(null, "<sandbox>");
|
||||
Database = database ?? new SandboxDatabaseHelper(null, "<sandbox>");
|
||||
Notify = notify ?? new SandboxNotifyHelper("<sandbox>");
|
||||
Notify = notify ?? new SandboxNotifyHelper();
|
||||
Scripts = scripts ?? new SandboxScriptCallHelper(null);
|
||||
}
|
||||
|
||||
|
||||
@@ -276,7 +276,7 @@ public class ScriptAnalysisService
|
||||
// mirrors production signatures so scripts compile identically, but it
|
||||
// does not deliver (production now enqueues into the site S&F engine,
|
||||
// which has no central-side equivalent here).
|
||||
var notify = new SandboxNotifyHelper(instanceLabel);
|
||||
var notify = new SandboxNotifyHelper();
|
||||
|
||||
var compileCache = new Dictionary<string, Script<object>>(StringComparer.Ordinal);
|
||||
var compileCacheLock = new object();
|
||||
|
||||
Reference in New Issue
Block a user