added moderation settings
This commit is contained in:
parent
1d8e622ab5
commit
f0fce82d27
3 changed files with 23 additions and 4 deletions
10
src/BirdsiteLive.Common/Settings/ModerationSettings.cs
Normal file
10
src/BirdsiteLive.Common/Settings/ModerationSettings.cs
Normal file
|
@ -0,0 +1,10 @@
|
|||
namespace BirdsiteLive.Common.Settings
|
||||
{
|
||||
public class ModerationSettings
|
||||
{
|
||||
public string FollowersWhiteListing { get; set; }
|
||||
public string FollowersBlackListing { get; set; }
|
||||
public string TwitterAccountsWhiteListing { get; set; }
|
||||
public string TwitterAccountsBlackListing { get; set; }
|
||||
}
|
||||
}
|
|
@ -66,7 +66,10 @@ namespace BirdsiteLive
|
|||
|
||||
var logsSettings = Configuration.GetSection("Logging").Get<LogsSettings>();
|
||||
services.For<LogsSettings>().Use(x => logsSettings);
|
||||
|
||||
|
||||
var moderationSettings = Configuration.GetSection("Moderation").Get<ModerationSettings>();
|
||||
services.For<ModerationSettings>().Use(x => moderationSettings);
|
||||
|
||||
if (string.Equals(dbSettings.Type, DbTypes.Postgres, StringComparison.OrdinalIgnoreCase))
|
||||
{
|
||||
var connString = $"Host={dbSettings.Host};Username={dbSettings.User};Password={dbSettings.Password};Database={dbSettings.Name}";
|
||||
|
|
|
@ -10,12 +10,12 @@
|
|||
},
|
||||
"AllowedHosts": "*",
|
||||
"Instance": {
|
||||
"Name": "BirdsiteLIVE",
|
||||
"Name": "BirdsiteLIVE",
|
||||
"Domain": "domain.name",
|
||||
"AdminEmail": "me@domain.name",
|
||||
"ResolveMentionsInProfiles": true,
|
||||
"PublishReplies": false,
|
||||
"MaxUsersCapacity": 1400
|
||||
"PublishReplies": false,
|
||||
"MaxUsersCapacity": 1400
|
||||
},
|
||||
"Db": {
|
||||
"Type": "postgres",
|
||||
|
@ -27,5 +27,11 @@
|
|||
"Twitter": {
|
||||
"ConsumerKey": "twitter.api.key",
|
||||
"ConsumerSecret": "twitter.api.key"
|
||||
},
|
||||
"Moderation": {
|
||||
"FollowersWhiteListing": null,
|
||||
"FollowersBlackListing": null,
|
||||
"TwitterAccountsWhiteListing": null,
|
||||
"TwitterAccountsBlackListing": null
|
||||
}
|
||||
}
|
||||
|
|
Reference in a new issue