mirror of
https://github.com/collinbarrett/FilterLists.git
synced 2026-03-11 09:04:27 +00:00
remove snapshot API endpoint in favor of Agent
This commit is contained in:
parent
9cd7dcd181
commit
d1b180b45c
1 changed files with 0 additions and 28 deletions
|
|
@ -1,28 +0,0 @@
|
|||
using System.Threading.Tasks;
|
||||
using FilterLists.Services.SnapshotService;
|
||||
using Microsoft.AspNetCore.Mvc;
|
||||
|
||||
namespace FilterLists.Api.V1.Controllers
|
||||
{
|
||||
public class SnapshotController : BaseController
|
||||
{
|
||||
private readonly SnapshotService snapshotService;
|
||||
|
||||
public SnapshotController(SnapshotService snapshotService)
|
||||
{
|
||||
this.snapshotService = snapshotService;
|
||||
}
|
||||
|
||||
[HttpPost]
|
||||
//TODO: convert API endpoint to server-side scheduled job
|
||||
public async Task<IActionResult> Index()
|
||||
{
|
||||
#if DEBUG
|
||||
await snapshotService.CaptureSnapshotsAsync(1);
|
||||
return Ok();
|
||||
#else
|
||||
return StatusCode(403);
|
||||
#endif
|
||||
}
|
||||
}
|
||||
}
|
||||
Loading…
Reference in a new issue