only return timestamps for episodes
This commit is contained in:
parent
a7db712acf
commit
7391bada8b
@ -88,6 +88,13 @@ public class SkipIntroController : ControllerBase
|
||||
[ActionName("UpdateTimestamps")]
|
||||
public ActionResult<TimeStamps> GetTimestamps([FromRoute] Guid id)
|
||||
{
|
||||
// only get return content for episodes
|
||||
var rawItem = Plugin.Instance!.GetItem(id);
|
||||
if (rawItem == null || rawItem is not Episode episode)
|
||||
{
|
||||
return NotFound();
|
||||
}
|
||||
|
||||
var times = new TimeStamps();
|
||||
if (Plugin.Instance!.Intros.TryGetValue(id, out var introValue))
|
||||
{
|
||||
|
Loading…
x
Reference in New Issue
Block a user