Fix type issues

This commit is contained in:
Ajay Ramachandran
2020-12-29 15:12:18 -05:00
parent 29ef770759
commit 7f0a35c88a
2 changed files with 2 additions and 2 deletions

View File

@@ -4,7 +4,7 @@ import {Request, Response} from 'express';
import { Category, VideoIDHash } from '../types/segments.model';
export async function getSkipSegmentsByHash(req: Request, res: Response) {
let hashPrefix: VideoIDHash = req.params.prefix;
let hashPrefix = req.params.prefix as VideoIDHash;
if (!hashPrefixTester(req.params.prefix)) {
res.status(400).send("Hash prefix does not match format requirements."); // Exit early on faulty prefix
return;