mirror of
https://github.com/freeCodeCamp/freeCodeCamp.git
synced 2026-05-28 18:26:54 +00:00
fix(client): show preview (#58629)
This commit is contained in:
committed by
GitHub
parent
5a74c19bf9
commit
6e6f13f85d
@@ -18,7 +18,7 @@ export type ChallengeFile = IncompleteChallengeFile & {
|
||||
error?: unknown;
|
||||
head: string;
|
||||
tail: string;
|
||||
seed: string;
|
||||
seed?: string;
|
||||
source?: string | null;
|
||||
path: string;
|
||||
history: string[];
|
||||
@@ -79,7 +79,6 @@ export function isPoly(poly: unknown): poly is ChallengeFile {
|
||||
'fileKey' in poly &&
|
||||
'head' in poly &&
|
||||
'tail' in poly &&
|
||||
'seed' in poly &&
|
||||
'history' in poly
|
||||
);
|
||||
}
|
||||
@@ -91,7 +90,6 @@ export function isPoly(poly: unknown): poly is ChallengeFile {
|
||||
typeof poly.fileKey === 'string' &&
|
||||
typeof poly.head === 'string' &&
|
||||
typeof poly.tail === 'string' &&
|
||||
typeof poly.seed === 'string' &&
|
||||
Array.isArray(poly.history);
|
||||
|
||||
return hasProperties(poly) && hasCorrectTypes(poly);
|
||||
|
||||
Reference in New Issue
Block a user