blob: a238a8e84931e10b7819344c021e8b686ef2d8a9 (
plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
|
using System.Text;
namespace MyDarling.Controllers;
public interface IRobotsTxtGenerator
{
public string GetRobotsText();
}
public class RobotsTxtGenerator : IRobotsTxtGenerator
{
public string GetRobotsText()
{
StringBuilder stringBuilder = new();
stringBuilder.AppendLine("user-agent: *");
stringBuilder.AppendLine("disallow: /freedom");
stringBuilder.AppendLine("disallow: /Account/");
return stringBuilder.ToString();
}
}
|